In that video at first N and p is declared as global variable but it is not working. Why?
Optimizations in prime sieve
There is no such reason. Sometimes, it happens due to available memory on your system.
You can try declaring them as global and it would work.
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.