Selection Sort and MinMax Sort