You are here: irt.org | FOLDOC | while loop
<programming> The loop construct, found in nearly all
procedural languages, that executes one or more instructions
(the "loop body") repeatedly so long as some condition
evaluates to true. In contrast to a repeat loop, the loop
body will not be executed at all if the condition is false on
entry to the while.
For example, in C, a while loop is written
while () ;
> is any expression and is any
statement, including a compound statement within braces
A for loop, e.g. in the C language, extends the while loop
syntax to collect pre-loop initialisation and loop-end logic
into the beginning of the statement.
Perl provides the "until" loop that loops until the loop
condition is true.
Nearby terms: Whetstone « Which Stands For Nothing « while « while loop » Whirlwind » White Book » White book CD-ROM
FOLDOC, Topics, A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X, Y, Z, ?, ALL
©2018 Martin Webb