js while index is greater than 0 i-- code example
Example: js for loops
let i;
for (i = 0; i < 6; ++i) {
console.log("Hello"); // print Hello 6 times
}
let i;
for (i = 0; i < 6; ++i) {
console.log("Hello"); // print Hello 6 times
}