heyy can you give more examples where no of querries is more so that i can understand the question more clearly
Question not clear
Please refer this:
what is the constraint for q?
but q is for the ith prime no so what maximum value of q is there upto which we have to find the prime no
heyy the eg you explained and for the given test case it works fine but wrong answers on two tc. Plaese explain.
Hi @Aparna you have to find upto the 10^5th prime number so change your sieve size according to that
its already initialised correctly. There is some other problem with the code Please tell
@Aparna value of the 10,000th prime number is 1,299,709 but the size of your array is 1,000,005 which is less than the required value
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.