Question #13634

Give an example of a function prototype. From your example, identify the return type, the function name and the argument list.

Expert's answer

int isprime(int value)
{
int x,j;
x=1;
& for (j=2 ; j<value; j++)
{ if ((value%j)==0) x=0; }
& if(x!=0) return 1;
& else return 0;
}

Here the return type is integer, the function name is "isprime" and the argument list is "int value".
LATEST TUTORIALS
APPROVED BY CLIENTS