exchanged insertion sort for quicksort