Its not working. help please


#1


var sleepCheck= function(numHours){
    if(sleepCheck>=8)
    {
        var string = "You're getting plenty of sleep! Maybe even too much!";
        
    }
    else{
       var string = "Get some more shut eye!";
    }
};

console.log(sleepCheck(10));
console.log(sleepCheck(5));
console.log(sleepCheck(8));


#2

sleepCheck is the name of the function.. you have to pose the condition on a variable.. not on the function itself...


#3

This variable declaration won't print anything to the display. Go back over the instructions and see if you need to return something to the console.


#4

yeah, re read carefully and make sure you understand whats being passed in. i'd read a loud the conditionals and explain to youtself whats happening


#5

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