Prime visits problem


Heres my code plz tell me where am i going wrong.?
only one testcase if failing

Just change the size of your sieve to 5000000.


Your modified code.