Name Roll No
Asher 36549
Abubakar 36565
Subhan 36577
Quicksort
Quicksort is a popular sorting algorithm that is often
faster in practice compared to other
sorting algorithms.
Itwas developed by Charles Antony Richard Hoare
(commonly known as C.A.R.
IMPORTANT POINTS
Like Merge Sort, QuickSort is a Divide and Conquer
algorithm. It picks an element as pivot and partitions the
given array around the picked pivot. There are many
different versions of quickSort that pick pivot in different
ways.
Always pick first element as pivot.
Always pick last element as pivot (implemented below)
Pick a random element as pivot.
Pick median as pivot.
Algorithm Of Quick Sort
Technique
C++ Code
Code