Node:repeat, Next:Reset, Previous:Rename, Up:Reference

### repeat

#### Synopsis

    repeat
      statement;
      ...
      statement;
    until boolean_expression;

#### Description

The `repeat ... until` statement declares a loop. For further description see repeat Statement.

#### Conforming to

`repeat` is defined in ISO 7185 Pascal and supported by all known Pascal variants.

#### Example

    program RepeatDemo;
    var
      Number, Sum: Integer;
    begin
      WriteLn ('Black Jack for beginners.');
      WriteLn ('You can choose your cards yourself. :-)');
      Sum := 0;
      repeat
        Write ('Your card (number)? ');
        ReadLn (Number);
        Inc (Sum, Number);
        WriteLn ('You have ', Sum, '.')
      until Sum >= 21;
      if Sum = 21 then
        WriteLn ('You win!')
      else
        WriteLn ('You lose.')
    end.

#### See also

Keywords, while Statement, for Statement.