showing run error nth prime number
Showing run error nth prime number
hello @guptashubham210a
a) ![]()
declare this as global array
b)
![]()
this should be n-1 (because indexing start from 0)
but why global array I am copying prime in vector which is global in primesevive function
I am copying prime nos from arr to vector
we need to prepare sieve upto 500 000 th prime number.
so find 500 000th prime number and compute sieve upto that.
ur updated code->https://ide.codingblocks.com/s/283660
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.
