What is the complexity of selection sort algorithms?
Show answerHide answer
Correct answer: (C) O(n²)
Explanation
Selection sort always makes about n²/2 comparisons, scanning the unsorted part for the minimum on each of n passes, so it is O(n²) in every case.