In QuickSort, evaluating pivot before the sorting conditions makes the algorithm work, while using its index to get its value within the conditions makes it fail, although t