I am not getting why it’s is showing the time exceed in first testcase.
I have applied correct quicksort algo i guess.
Kindly help me in reducing time limit in it.
Help with first testcase in quicksort problem in recursion
submitted on the link of ide you have mentioned
@sumitlohan,
I have modified your code. https://ide.codingblocks.com/s/175155 See, your code was absolutely correct but since Quicksort has a complexity of O(n^2) in worst case it was giving TLE. Hence, we will use randomized Quicksort which gives complexity of O(n*Log(n)), to avoid the TLE.
sorry sir but i am getting run error this time in 1st testcase
Yes sir i m done with the submission