QUICK SORT problem in recursion part

test case 1 is not passing giving run time error

please help with the doubt

@Jainish-Patel-1007094602980100
The problem is with your array declaration. When you declare it as
int a[n];
Since the allocation occurs at compile time, it picks a random value for n and assigns memory accordingly. To be safe, allocate the highest memory as per the given constraints, infact a bit more.
int a[200005];
This will work.