ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
Do you have a collection of Interview Questions and interested to share with us!!
Please send that collection to along with your userid / name. ThanQ
Google
 
Categories  >>  Software  >>  Programming Languages  >>  C
 
 


 

 
 C interview questions  C Interview Questions
 C++ interview questions  C++ Interview Questions
 VC++ interview questions  VC++ Interview Questions
 Delphi interview questions  Delphi Interview Questions
 Programming Languages AllOther interview questions  Programming Languages AllOther Interview Questions
Question
Which of the following sorts is quickest when sorting the 
following set: 1 2 3 5 4


	

1) Quick Sort 	 


2) Bubble Sort 	 


3) Merge Sort 	 

 Question Submitted By :: Viju
I also faced this Question!!     Rank Answer Posted By  
 
  Re: Which of the following sorts is quickest when sorting the following set: 1 2 3 5 4 1) Quick Sort 2) Bubble Sort 3) Merge Sort
Answer
# 1
1) Quick sort
 
Is This Answer Correct ?    6 Yes 0 No
K.kavitha
 
  Re: Which of the following sorts is quickest when sorting the following set: 1 2 3 5 4 1) Quick Sort 2) Bubble Sort 3) Merge Sort
Answer
# 2
Merge Sort.
 
Is This Answer Correct ?    2 Yes 0 No
Keerthana
 
 
 
  Re: Which of the following sorts is quickest when sorting the following set: 1 2 3 5 4 1) Quick Sort 2) Bubble Sort 3) Merge Sort
Answer
# 3
bubble sort
 
Is This Answer Correct ?    1 Yes 1 No
Mini
 
  Re: Which of the following sorts is quickest when sorting the following set: 1 2 3 5 4 1) Quick Sort 2) Bubble Sort 3) Merge Sort
Answer
# 4
Quick Sort, Since the array is already sorted, so this can 
be considered as Best case example. The complexity of quick 
sort in best case is O(n log n). No doubt , same is the 
complexity of Merge sort in best case, but Quick sort 
enjoys priority over Merge Sort because Merge sort requires 
extra memory( an array) to store the sorted result whereas 
quick sort do not specify any such need.
 
Is This Answer Correct ?    2 Yes 0 No
Prof.gagandeep Jagdev
 
  Re: Which of the following sorts is quickest when sorting the following set: 1 2 3 5 4 1) Quick Sort 2) Bubble Sort 3) Merge Sort
Answer
# 5
quick sort is the best sorting algorithm because time 
complexity is O(nlogn)
 
Is This Answer Correct ?    0 Yes 0 No
Rohith
 

 
 
 
Other C Interview Questions
 
  Question Asked @ Answers
 
The differences between Windows XP and Windows Visa HCL7
write a program to sort the elements in a given array in c language  2
write a program in c language for the multiplication of two matrices using pointers? Ignou5
can we access one file to one directory?  1
I have an array of 100 elements. Each element contains some text. i want to: append a star character to the end of every fifth element remove every second character from every tenth element, and… add a line feed (ascii 10) after the 30th character of every array element whose length is greater than 30 characters.  1
what is array?  6
What is the output of the following program #include<stdio.h> main() { int i=0; fork(); printf("%d",i++); fork(); printf("%d",i++); fork(); wait(); } ADITI5
write a c program to accept a given integer value and print its value in words  3
palindrome for strings and numbers----Can anybody do the prog? TCS6
1.what are local and global variables? 2.what is the scope of static variables? 3.what is the difference between static and global variables? 4.what are volatile variables? 5.what is the use of 'auto' keyword? 6.how do we make a global variable accessible across files? Explain the extern keyword? 7.what is a function prototype? 8.what does keyword 'extern' mean in a function declaration?  1
program to find a smallest number in an array Microsoft5
Write a program to print all the prime numbers with in the given range ABC1
#define d 10+10 main() { printf("%d",d*d); }  3
CopyBits(x,p,n,y) copy n LSBs from y to x starting LSB at 'p'th position. Adobe4
write a programe returns the number of times the character appears in the string  1
write the program for maximum of the following numbers? 122,198,290,71,143,325,98  4
Reverse the part of the number which is present from position i to j. Print the new number.[without using the array] eg: num=789876 i=2 j=5 778986  2
difference between i++* and *++i IBM3
How to reverse a string using a recursive function, with swapping?  4
I have an array of 100 elements, each of which is a random integer. I want to know which of the elements: a) are multiples of 2 b) are multiples of 2 AND 5 c) have a remainder of 3 when divided by 7  1
 
For more C Interview Questions Click Here 
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com