Two more common mistakes: (that means ones that I do frequently)
N = 2;
X = 3;
. . .
if (x > 10);
{
return(N);
}
N = 7;
return(N);
and:
N = 2;
X = 3;
. . .
if (x = 10)
{
return(N);
}
N = 7;
return(N);
Look for why both sections return 2 instead of 7.