Hello. I have an excercise that asks the following:
Consider a modification to QuickSort, such that each time "Partition" is called, the median of the portioned array is found and used as a pivot. Write a pseudocode fo that.
I'm not asking for the answer. I just want to know what the median is. Is it the number that splits the array in half?
i.e: In case of (1,2,3,4,5,6,7,8,9) the median is 5?