Lesson 12. OR


#1

https://www.codecademy.com/courses/javascript-beginner-en-qDwp0/2/3?curriculum_id=506324b3a7dffd00020bf661

I don't see the error in the line of code. I keep on getting this error message

Oops, try again.
It looks like your function doesn't return true when tired is true and bored is false.


var tired = true;
var bored = false;

var nap = function() {
    if(tired || bored) {
        return false
    } else {
        return false
    }
};


#2

NEVERMIND I AM A COMPLETE IDIOT I FIGUIRED IT OUT

Both returns were false


#3

You also forgot to put something in the function parenthesis.


#4

that isn't necessary tho


#5

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