add quicksort which uses median3 to partition.