Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


What are the average number of comparisons required to sort
3 elements?

Answers were Sorted based on User's Feedback



What are the average number of comparisons required to sort 3 elements?..

Answer / jaiprakash

n(n-1)/2(bubble sort)
n=3
(3*2)/2=3(n)

ans:n

Is This Answer Correct ?    13 Yes 1 No

What are the average number of comparisons required to sort 3 elements?..

Answer / hell2heaven

I think answer is 3.is it right?

Is This Answer Correct ?    12 Yes 1 No

Post New Answer

More C Interview Questions

write a own function for strstr

1 Answers   LG Soft,


Write a program to add a given duration with time(24hrs format)

1 Answers   Protech,


shorting algorithmS

0 Answers   Wipro,


pascal triangle program

2 Answers  


How can I insert or delete a line (or record) in the middle of a file?

0 Answers  


In which layer of the network datastructure format change is done

0 Answers   Honeywell,


What are structures and unions? State differencves between them.

0 Answers   iNautix,


How do you determine a file’s attributes?

0 Answers  


Explain spaghetti programming?

0 Answers  


Write a main() program that calls this function at least 10 times. Try implementing this function in two different ways. First, use an external variable to store the count. Second, use a local variable. Which is more appropriate?

2 Answers  


Is both getch() and getchar() functions are similar? if it is similar means why these two functions are used for same usage? if it is not similar means what is the difference?

1 Answers   Infosys,


Is array name a pointer?

0 Answers  


Categories