Find great deals on eBay for Woodstock Ticket in Music Memorabilia. Shop with confidence.
Instead of adding several almost equal lines in a script we can use loops to perform a task like this. In JavaScript there are two different kind of loops: for - loops through a block of code a specified number of times. while - loops through a block of code while a specified condition is true.
The While statement. The While statement is a control flow statement that allows code to be executed repeatedly based on a given boolean condition. This is the general form of the While loop: The While keyword executes the statements inside the block enclosed by the While, End While keywords.