0
What is the fastest sorting algorithm ?
Some argue that quick sort is fastest but there are algorithms like parallel merge sort which have better time complexity what is the fastest algorithm you know or have come across?
1 Resposta
+ 3
2
Merge Sort is the fastest stable sorting algorithm with worst-case complexity of O(nlogn), but it requires extra space. Although, if memory constraints are very tight you can use Quick Sort, whose worst-time compelxity is O(n2n2) but average case complexity is O(nlogn).
A sorting algorithm is stable if whenever there are two records R and S with the same key, and R appears beforeS in the original list, then R will always appear before S in the sorted list.
and offcourse inbuilt function of c/c++ is the fastest (hehehe)