|
| 09 Jun 2015 04:32 PM |
confirm("are you ready to play?"); var age = prompt("What is your age?"); if (age <= 13){ console.log("You can play but we take no responsibility, ask your parents for permission!"); } else { console.log("good luck and enjoy the game"); } 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("Rate 1-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.") }
|
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
| |
|
eLunate
|
  |
| Joined: 29 Jul 2014 |
| Total Posts: 13268 |
|
|
| 09 Jun 2015 04:34 PM |
| That's pretty meh grade dude |
|
|
| Report Abuse |
|
|
|
| 09 Jun 2015 04:35 PM |
| for userAnswer use confirm() |
|
|
| Report Abuse |
|
|
|
| 09 Jun 2015 04:40 PM |
| That script looks familiar... Coder dojo? |
|
|
| Report Abuse |
|
|
| |
|
|
| 09 Jun 2015 04:41 PM |
| Haha! What a coincidence! I helped you with that! |
|
|
| Report Abuse |
|
|
| |
|
|
| 09 Jun 2015 04:46 PM |
| You go to the Austin coder dojo place, correct? I mentor there |
|
|
| Report Abuse |
|
|
| |
|