Skip to content

while Loops

Introduced
Handout
Video lesson for this topic Open the video page
7:57

Selection and Iteration

Here are three loops. The first two differ by one character — a less-than instead of a less-than-or-equal. The first runs ten times. The second runs eleven.…

English narration · English and 中文 subtitles you can switch

In this lesson

Video lesson
Vocabulary
English Meaning
while loop/waɪl luːp/A loop that tests its condition before each iteration and repeats while the condition is true.
loop control variable/luːp kənˈtrəʊl ˈveərɪəbl/
infinite loop/ˈɪnfɪnət luːp/A loop that continues indefinitely because its stopping condition is never reached or no stopping condition is provided.

Handout

Log in or create account

IGCSE, A-Level & AP