For the problem [QUALPREL]. I have the following two solutions in Java:
First solution simple algorithm to reverse the array. Whereas, second solution Java inbuild Collections.reverseOrder() method to reverse sort the array.
I am not sure why the second one is giving me wrong answer. Can someone help me clearify the problem? Thanks in advance