2.If / else if /else am I missing a ")"?


2.If / else if /else

The error message is:

missing ) after condition
but I don't think I am. Am I?

var isEven=function(number) {
if (number%2===0){ return true;}
else if (number isNaN===true) {return "that is not a number";}
else {return false;}


Your else if condition should be (isNaN(number)).


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.