Menu
Riverview Church

WHILE

while is a loop that executes when the condition is true.

It is similar to a for loop but has different syntax.

SYNTAX

while (condition) {
    code
}

EXAMPLES

INTERNAL

do while

for

for in

for of

EXTERNAL

https://developer.mozilla.org/en/JavaScript/Reference/Statements/while