Topic summary
While loop

Extracted from the Wikipedia article Loop (statement).
Pre-test loop
A pre-test loop is a conditional loop where the condition is checked before the body is executed. More precisely, the condition is checked and if it holds the body is execute. Afterwards, the condition is checked again, and if it holds the body is executed again. This process repeats until the condition does not hold. Many programming languages call this loop a while loop and refer to it with the keywordwhile. They are commonly formatted in manner similar to