1. If / else



Does anyone know what I'm doing wrogn here? Here's the error message:

"Oops, try again.
Looks like your function returns false when number = 3. Check
whether your code inside the if/else statement correctly returns true if
the number it receives is odd."

var isEven = function(number) {
  // Your code goes here!
  if(number % 2 === 0) {
  return "true";
  else {
  return "false";


you should return Boolean values (True and False), so without quotation marks (")


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