Implementation of the quicksort sorting algorithm