High level code are quite simple ( divide/conque, recursively partition the array):
(low < high)
/* pi is partitioning index, arr[p] is now
at right place */
pi = partition(arr, low, high);
// Separately sort elements before
// partition and after partition
quickSort(arr, low, pi - 1);
quickSort(arr, pi + 1, high);
The key is how to partition in-place?
Here a pretty good quick sort ( random pivot ) video , keep l, r index
There are some other partition strategy like always choose the last or first element.