0 votes 0 votes Which of the following sorting techniques have best time complexity, if complexity is measured in terms of number of comparison? A Insertion sort B Selection sort C Merge sort D QuickSort Algorithms made-easy-test-series algorithms sorting time-complexity + – rahul sharma 5 asked Dec 8, 2017 • edited Mar 7, 2019 by Aditi Singh rahul sharma 5 1.0k views answer comment Share Follow See 1 comment See all 1 1 comment reply Mohit Kumar 6 commented Apr 27, 2020 reply Follow Share It depends on lot of factors. 1. Size of input. => Quick sort 2. How well is it sorted. => Insertion sort 3. Can your system allot more space for sorting to function. => Merge sort i think question is incomplete, 0 votes 0 votes Please log in or register to add a comment.
0 votes 0 votes In best case input, insertion sort. In worst case input, merge sort. vishalshrm539 answered Dec 8, 2017 vishalshrm539 comment Share Follow See all 2 Comments See all 2 2 Comments reply rahul sharma 5 commented Dec 8, 2017 reply Follow Share Please give one best answer as per option 0 votes 0 votes vishalshrm539 commented Dec 9, 2017 reply Follow Share One answer could be merge sort. 1 votes 1 votes Please log in or register to add a comment.
0 votes 0 votes In worst case input merge sort is better. abhishekmehta4u answered Mar 8, 2019 abhishekmehta4u comment Share Follow See all 2 Comments See all 2 2 Comments reply Priyadrasta Raut commented Oct 22, 2019 reply Follow Share the question is given to measure time complexity on the basis of no of comparisons not the asymptotic meaning 0 votes 0 votes Satbir commented Oct 22, 2019 reply Follow Share Time complexities can be obtained based on number of comparisons. 0 votes 0 votes Please log in or register to add a comment.