Hel me with The story heats up!


#1


the story heats up!


https://www.codecademy.com/courses/javascript-beginner-en-x9DnD/0/5?curriculum_id=506324b3a7dffd00020bf661#


// Check if the user is ready to play!
//confirm("I'm ready to play");
console.log("You are at a Justin Bieber concert, and you hear this lyric 'Lace my shoes off, start racing.'");
console.log("Suddenly, Bieber stops and says, 'Who wants to race me?'");
var userAnswer;
var userAnswer=prompt("Do you want to race Bieber on stage?");
if (userAnswer === "yes") {
    console.log("You and Bieber start racing. It's neck and neck! You win by a shoelace!");
} else  {
console.log("Oh no! Bieber shakes his head and sings 'I set a pace, so I can race without pacing.'");
}


i have a error: Oops, try again. Did you add an else statement to your code? or this: Oops, try again. Did you add an if statement to your code?
can someone help me with this?


#2

You seem to be missing sections of code from earlier parts of the lesson like the if statement about the age of player has to be over 13 or too young and the else statement that goes along with it. Go back and make sure you have carried over all your code and if not go back and create these.


#3

some bug thx a lot man!!!


#4

No problem! happy coding :smiley:


#5

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