It looks like you didn't print the introduction


#1

Hi.
I can`t understand what is the problem?

<<<var age = prompt("What`s your age");
if (age < 13) {
console.log("you can play, but i take no responsibility");
}
else {
console.log ("play on !");
}

console.log("When I was playing, I made a couple of errors!");>>>
program write - "Oops, try again. It looks like you didn't print the introduction. "


#2

@mxsneli,
Probable cause is NOT following the Instructions....
try a google search

"Oops, try again. It looks like you didn't print the introduction. " site:codecademy.com

Reference

google search
== the Book ==
javascript [your question] site:developer.mozilla.org

== discussions / opinions ==
javascript [your question] site:stackoverflow.com

== guidance ==
www.crockford.com
http://javascript.crockford.com/code.html
http://javascript.crockford.com/survey.html
http://stackoverflow.com/questions/9549780/what-does-this-symbol-mean-in-javascript
https://developer.mozilla.org/en-US/docs/Web/JavaScript/A_re-introduction_to_JavaScript
www.developer.mozilla.org/en-US/docs/Web/JavaScript/Guide
http://stackoverflow.com/questions/336859/var-functionname-function-vs-function-functionname?rq=1


#3

@mxsneli step 3 of the lesson states "print out the following introduction, exactly as it is written"

I don't see where you are printing the introduction here.


#5

Thanks a bunch!
I google "Oops, try again. Did you add an if statement to your code?".

The solution (http://stackoverflow.com/questions/36476936/codeacademy-if-else-javascript):

Occasionally, Codeacademy incorrectly reports errors in your code based on trivial whitespace differences. Based on the output of your script, you've written your code correctly.

Funnily enough, using a ternary operator instead of an if statement works fine:

// Check if the user is 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 = prompt("Do you want to race Bieber on stage?");

console.log( userAnswer === "yes" ?
"You and Bieber start racing. It's neck and neck! You win by a shoelace!" :
"Oh no! Bieber shakes his head and sings 'I set a pace, so I can race without pacing.'");