why my code is showing no output?
please resolve.
Prateek loves candy
ok,but still i am getting one testcase as no output.
but this is with vectors,whats the issue with this code sir?
So issue was
Firstly prime array size should be around 10 times the max nth prime you want to print
Then your code was fine but gave TLE in last test case
That is because for each query you were traversing an array of 10^6 range
Instead I saved all the primes in a vector and simply returned nth prime