Programmers. Is is insertion sort faster than selection?

Monza

Member
Jan 15, 2000
131
0
0
The algorithm for selection i faster than insertion sort. But if you want the fastes way you would look at QuickSort and QuickSelect.

inerstionsort is O(N^2) ond
quicksort is O(NlogN)

its very faster on fields that is quite high.
 

hans007

Lifer
Feb 1, 2000
20,212
18
81
man , i should know the answer to this. oddly i remember all the algorithms but not the names for them. bubble is usually faster.