0
Why is this showing me this message and how can i fix it
3 Answers
+ 3
And
for(int j=i-1; i<0 ; j--)
i<0 never, true because you are staring from i=2
if it j<0,then if once, then always true, infinite loop. Because you are decreasing j, not I.
Check one by one condition...
OK. I already added code in your last question..
static bool isPrime(int x)
{
for( int i=2; i<=x/2; i++)
if(x%i== 0)
return false;
return true;
}
0
Thanks again for all your hrlp