Helping is appreciated, :) - 3. Adding some story


#1

Hello Peepz,

I'm stuck on 3. Adding some story..
I don't even know what I'm doing wrong, I've searched almost every topic but it won't help.

Please help and explain what I'm doing wrong.. Only posting the result won't help me. Thanks!


// Check if the user is ready to play!
confirm("I am ready to play!");
var age = prompt("What's your age?");
if (age < 13) {
console.log = ("you are allowed to play but I take no responsibility.");
}
else {
console.log = ("Keep playing");
}
console.log = ("You are at a Justin Bieber concert, and you hear this lyric 'Lace my shoes off, start racing.'");


The last console.log within { } doesn't work either


#2

Hi the error is at your console.log they should be like that

console.log("here go your story")

Instead of

console.log = ()

Hope I could help you.


#3

When I removed the "=" I've got another error.
TypeError: console.log is not a function

Like this:
console.log("you are allowed to play but I take no responsibility.");
or
console.log("you are allowed to play but I take no responsibility.")

,Thank you


#4

Can you post all your new code.


#5

Wow. OK. I accedently closed the google tab. reopened the tab and bang..
It worked.


// Check if the user is ready to play!
confirm("I am ready to play!");
var age = prompt("What's your age?");
if (age < 13) {
console.log("you are allowed to play but I take no responsibility.");
}
else {
console.log("you are allowed to play but I take no responsibility.");
}
console.log("You are at a Justin Bieber concert, and you hear this lyric 'Lace my shoes off, start racing.'");


Thank you for helping me it worked and now I know what I did wrong! :slightly_smiling:


#6

This is what you need to put for it

console.log("You are at a Justin Bieber concert, and you hear this lyric 'Lace my shoes off, start racing.'");
confirm("I understand confirm!");
var age = prompt("What's your age");
if("age is less than 13") {
console.log("You or allowed to play but you take no responsibility!");
}else{
console.log("Good job and be hard to hit!");
}