- script.js
JavaScript
var score;
Result
Goalscompleted
Write the main program loop with muffin.getScore()
.
- Set variable
score
the value from commandmuffin.getScore()
. - Add loop
while (score > -1) { }
under the variable. “Timeout error” might be logged on this and the next step. This is normal. - Inside the loop, log the variable
score
in the console. - In the same place, after logging the variable in the console, once again set the variable
score
the value from themuffin.getScore()command
.
Comments