Randomised quick sort

what is randomised quicksort as i was unable to pass testcase 0 here is the link to my code https://ide.codingblocks.com/s/230312

Shreya, in case of quicksort… The worst case time complexity is O(N^2) as in case of complete reverse array…given as a input…
So for that case… You can apply a shuffle function on the given input so that you get a random array…and then you can easily apply quicksort algorithm whose time complexity will be
O(N logN)…
You can refer to the function as :
void shuffle(ll a[], ll s, ll e)
{
srand(time(NULL));
int j;
for(int i=e;i>0;i–)
{
j= rand()%(i+1); // as e is n-1
swap(a[i],a[j]);
}
}

its not helping :confused: i still get a testcase wrong pls help

It worked thank you so much haaaaa!