var isEven = function(number) {

if (number % 2 === 0) {

return true;

} else if (isNaN(number)){

return "You did not input a number!";

} else {

return false;

}

};isEven(12);

I know that the above code works, and lets me continue in the lesson. but....

I tried to be a little more creative, and i'm curious if this would work and i'm being denied because of the lesson or because of my code? I really want to figure this out it's bugging me!

var isEven = function(number) {

if (number % 2 === 0) {

return "Your number " + number + " does in fact divide evenly by 2";

} else if (isNaN(number)){

return "You did not input a number!";

} else {

return "Your number " + number + " does not evenly divide by 2!";

}

};isEven(prompt("Input a number to see if it is divided evenly by 2"));

*Error code: Oops, try again. Your function returns true for 3!*

Thank you in advance for your help!