5/7 "Oops, try again. Did you remember to put in the 'yes' answer option?"


#1

confirm("I'm ready to play!");
var age = prompt("What is your age?");
if (age >= 13) {
console.log("Let's get started!");
} else {
console.log("Sorry, you must be at 13 years old 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 = 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.'")
}


#2

Nevermind, I was wrong.


#3

var age = prompt("What's your age");
if(age < 13)
{
console.log("Get off the internet")
}
else {
console.log("Welcome to the internet buddy!")
}
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 = 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.'")
}
var feedback = prompt("Please rate my game out of 10")
if(feedback > 8)
{
console.log("Thank you! We should race at the next concert!")
}
else {
console.log("I'll keep practicing coding and racing.")
}


#4

My 5/7 is different but still has the same error. The code works just fine.

var age = prompt ("what is your age?")
console.log("Snow White and Batman were hanging out at the bus stop, waiting to go to the shops. There was a sale on and both needed some new threads. You've never really liked Batman. You walk up to him.");
console.log("Batman glares at you.")
var userAnswer=prompt("Are you feeling lucky, punk?")
if (userAnswer === "yes") 
{
    console.log("Blah blah")
} 
else 
{
    console.log("No no no")
}

#5

Yet you didn't do the directions.

You have to follow the directions exactly.

So it has to be with Justin Bieber. :neutral_face:

It has to have an age question in an if loop, with the requirement of 13.

Etc, etc, etc....


I suggest you go back with the levels or something if you did it like this continuously, else you should do it exactly as it tells you to.