A list is ordered from smaller to largest when a sort is
called. Which sort would take the longest time to execute?

Answer Posted / vinoth kumar.r

Quick sort's worst case is the one given in the question.
It exhibits selection sort type of procedure when the list
is sorted

Hence both :)

Is This Answer Correct ?    8 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is an object array?

529


What is declaring array?

480


Can you provide some implementation of a dictionary having large number of words?

722


Mention one advantage and disadvantage of using quadratic probing?

602


Can we use any class as map key?

456






Differentiate between hashset and hashmap.

518


What is data and information explain with example?

553


What is the use of tree data structure?

483


How do you initialize an arraylist?

501


How does sort function work?

506


What is a reverse linked list.

598


What type of algorithm is binary search?

471


What are the difference between a stack and a queue?

529


Why is quicksort faster than merge sort?

524


What is sort order?

494