While Loop Counter in JavaScript
Level 265 keystrokes
A while loop repeats code as long as the condition is true.
JavaScript code
// let declares a variable that can be changed// Initialize count to 01let count = 0;// while loop runs while count is less than 32while (count < 3) { // Output current value of count3 console.log(count); // Increment count by 14 count++;5}Output
0 1 2
Practice typing this code. Results are not recorded in the rankings.
Symbols in this code
The symbols you type in this JavaScript code and how often they appear.
;× 3(× 2)× 2+× 2.× 1{× 1}× 1<× 1=× 1