Deepak and primes


2 test cases are not getting passed

Hi @mehak61
Your two test cases are showing run error because of the value of N. As we need to find nth prime number where n<5000000 so you have to make N as 100000000. Making N as 100000000 will make your code pass all the test cases.

Hi @Aayush
I changed the value of N yet the two test cases are failing.

Hi @mehak61
The code you have shared is having a while loop for test cases but in the question you only have to take n as input, t input is not required which is why it was giving TLE.

Your corrected code try it :