Repeat

From Free Pascal wiki
Revision as of 00:10, 15 October 2020 by Rfc1394 (talk | contribs) (clean up syntax)
Jump to navigationJump to search

Deutsch (de) English (en) suomi (fi) français (fr) русский (ru)

The reserved word repeat is used as a loop instruction where the test occurs after the loop is executed. It is a control construct that is similar to a while-do loop.

Syntax

  repeat
    <statement block>
  until <condition>;

Example

  x := 1;
  repeat
    DoSomethingHere(x);
    x := x + 1;
  until x = 10;



Keywords: begindoelseendforifrepeatthenuntilwhile