implemented own quicksort