We have to partially sort an array in descending order.
I know std::partial_sort but it does it in ascending order.
http://en.cppreference.com/w/cpp/algorithm/partial_sort.
Is their any other such function that can do so or any fast algorithm to do so.
The second overload in the reference you linked to takes a Comparer – pass in an instance of
std::greater<T>.