12. Functions and If / Else HELP PLEASE!


#1



Replace this line with your code.


#2

Please paste in your code + lesson + error..
We can only help you if you provide us with your code

Thanks


#3

what do you need help with for if/else statements?


#4

var sleepCheck = function(numHours) {
if(numHours >= 8) {
return "You're getting plenty of sleep! Maybe even too much!";
}
else {
return "get some more shut eye!";
}
};
console.log(sleepCheck(10));
console.log(sleepCheck(5));
console.log(sleepCheck(8));

I've tried so many different things, stuck on this for hours! I get all the right answers yet it says I didn't for 5 hours


#5

please help I'm desprate


#6

Capital g for Get, most likely the problem, exercise is picky on correct grammar/punctuation


#7

Hallelujah!!! Thank you so much that took e hours and multiple tries!!!!! I even spent an hour looking at replies at other posts to help me! You're the best!!!!!
Namaste


#8

that was all one big waste of time for a capital letter


#9

Thanks again Benjnev!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!