Functions & if / else HELP


// Write your function below.
// Don't forget to call your function!
var sleepCheck = function(numHours)
if (numHours >= 8)
return "You're getting plenty of sleep! Maybe even too much!";
else (numHours <=8)
return "Get some more shut eye!";
console.log (sleepCheck(10));
console.log (sleepCheck(5));
console.log (sleepCheck(8));

I am stuck again. i cant get it to work.

Replace this line with your code.


Hi your code should go inside the function sleepCheck() like that

var sleepCheck = function(numHours) { #open the sleepCheck function

#here go your  if and else statement 

} #close the sleepCheck function


Thank you that makes total sense.


And return statements shouldn't have quotation marks in them.