2. Old enough to play?


#1

// 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 ("Play on my friend!)
}

COULD ANYONE TELL ME WHAT'S WRONG WITH THIS?


#2

I've added semi colons and it still doesn't work:

// Check if the user is ready to play!

confirm ("Are you ready to play?");

var age = prompt ("Whats your age");

if(age < 13) {
console.log ("You are allowed to play, but I am not responsible!");
}
else {
console.log ("Play on my friend!);
}


#3

I needed a " at end of "play on my friend!)

SOLVED.