while-loop.pas

PROGRAM while_loop;
VAR
    x: integer = 0;
BEGIN
    while x < 10 do
        // do something
        x += 1;

    WRITELN(x);
    // 10
END.