In computer science, selection sort is an in-place comparison sorting algorithm. Selection sort is noted for its simplicity and has performance advantages over more complicated algorithms in certain situations, particularly where auxiliary memory is limited.
Time (middle/the worst) | Memory (middle/the worst) |
---|---|
O(n^2)/O(n^2) | O(1)/O(1) |