What is wrong with my code?


#1

var isEven = function(number) {
if(number % 2 === 0){
return "It's even!";
} else if(isNaN(number)){
return "Your input is not a number.";
} else {
return "It's not even.";
}
};

isEven(3);


#2

For the even and odd case you need to use the boolean values true and false, just the IsNaN case can use a string to be returned.