可能重复:
What sort algorithm provides the best worst-case performance?
哪种方法可用于对整数数组进行排序?快速排序是否有效? [垃圾链接删除]
中提到了一些用于排序的常用方法答案 0 :(得分:1)
它们具有不同的排序方法,具有不同的功能。
Bubble Sort [It's simple but not good for large data][1]
Selection Sort [Selection sort is noted for its simplicity, and also has performance advantages over more complicated algorithms in certain situations, particularly where auxiliary memory is limited.][2]
Insertion Sort [It is much less efficient on large lists than more advanced algorithms such as quicksort, heapsort, or merge sort.][3]
Quick Sort [Quicksort is often faster in practice than other O(nlogn) algorithms][4]
Merge Sort [Merge sort is an O(n log n) comparison-based sorting algorithm][5]
Heap Sort [it has the advantage of a more favorable worst-case O(n log n) runtime. Heapsort is an in-place algorithm, but is not a stable sort.][6]