Loops and Ranges
Do While Loops
Run the body before checking the condition.
Do While Loops
do_while_loop.js
const target = 3;
let current = 0;
let passes = 0;
do {
current += 1;
passes += 1;
} while (current < target);
console.log("target=" + target);
console.log("current=" + current);
console.log("passes=" + passes);
do-while-loop
A `do...while` loop always executes its body at least once, then checks whether another iteration should run.