sir it is giving runtime error please check
Number of div doubt
@Shivanchal-Agarwal-2530139037020445 hey, s[j] may be 0 and you are dividing it by some number thats why it is giving runtime error,apply if condition or use some other logic it will work.
sir s[j] represents all the prime numbers starting from 2 then how will it be zero?
@Shivanchal-Agarwal-2530139037020445 hey thats why I am saying there is problem in that part and it is dividing by 0 therefore giving wrong answer , check this corrected code:
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.