Which of the following sorting algorithms has best case time complexity of O(nlog(n))?
Question
Which of the following sorting algorithms has best case time complexity of O(nlog(n))?
Solution
The sorting algorithms that have the best case time complexity of O(nlog(n)) are:
- Merge Sort
- Heap Sort
- Quick Sort (although the worst case is O(n^2), the "average" case is O(nlog(n)) and can be optimized to avoid the worst case)
- Shell Sort (although it can perform better than O(nlog(n)) in some cases)
Please note that these are not the only sorting algorithms with this time complexity, but they are some of the most commonly used.
Similar Questions
Which of the following sorting algorithm has best case time complexity of O(n2)?
Which of the following sorting algorithm has best case time complexity of O(n2)?ans.selection sortstupid sortinsertion sortbubble sort Previous Marked for Review Next
What is the worst case complexity of selection sort? a) O(nlogn) b) O(logn) c) O(n) d)
What is the best case time complexity of insertion sort? Please select the tightest Big-O bound of those listed below. Group of answer choices O(n) O(nlogn) O(n2) O(2n)
For which of the following algorithms is O(n^2) the best-case time complexity?Quick sortMerge sortInsertion sortBubble sort
Upgrade your grade with Knowee
Get personalized homework help. Review tough concepts in more detail, or go deeper into your topic by exploring other relevant questions.