5th and 6th test cases are failing
https://ide.codingblocks.com/s/60530
D eepak and primes
Hi,
you have to use bitwise sieve or use bitset. this is because when you change the range of n (as described in above point) you can not use your array pp (max size 10^8) so use bitwise sieve or simple bitset.
Note : 5,000,000 th prime number is 86,028,121. Thus you need to set the size of “pp” (in your code) to a number greater than 86,028,121
Correct Code : https://ide.codingblocks.com/s/58420 2 1
Hit like if you get it!!
Hi Pratik,
as you are not responding to this thread, I am marking your doubt as Resolved for now. Re-open it if required.
Please mark your doubts as resolved in your course’s “ Ask Doubt ” section, when your doubt is resolved.