Let's have an array where first half are of value 50 and the second half 100. What would be the asymptotic performance when sorting using Quicksort.
I think it it should be $O(n^2)$ as for array of same elements the complexity is $O(n^2)$ and this particular problem could be rewritten as sorting the first half + sorting the second hald $O(2*(\frac{n}{2})^2 + n)$ which is still $O(n^2)$.
But my schoolmates claim it should be $O(n log(n))$.. so which one is correct?