问题
Possible Duplicate:
What sort algorithm provides the best worst-case performance?
Which is the best method that can be used to sort an Integer array?Is Quick Sort efficient? Some of the common methods used for sorting are mentioned in [spam link removed]
回答1:
They are different sorting methods are available with different features.
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]
来源:https://stackoverflow.com/questions/6907178/which-is-the-best-method-used-for-sorting