I am stuck!


#1

What am I supposed to do?

var isEven = function(number) {
  // Your code goes here!
  if(number % 2 === 0) {
      return true;
  } else if(number === isNaN("?")) {
      return "Your input is not a number";
  } else {
      return false;
  }
};

#2

else if (isNan(number))

Think this works


#3

You check if number isNan. isNan means is Not a Number.


#4

Just your reply give me the intuition that function name is abbreviated to what is it's responsability :smiley:


#5

You're welcome, the first time I saw isNaN I had to google it. Save you a bit trouble! :slightly_smiling:


#6

A post was split to a new topic: I am stuck!


#7