Sorting
Almost half of all CPU cycles are spent on sorting!
- Input: array X[1..n] of integers
- Output: sorted array (permutation of input)
In: 5,2,9,1,7,3,4,8,6 Out: 1,2,3,4,5,6,7,8,9
- Assume WLOG all input numbers are unique
- Decision tree model count comparisons “<”