Answers for "prime[total++] = i"

0

prime[total++] = i

bool isprime(int n)
{
    int i;
    for(i=2;i<=sqrt(n);i++)
        if(n%i==0)
            return false;
    return true;
}
Posted by: Guest on December-06-2020

Browse Popular Code Answers by Language