Until/ru: what changed
Revision 1 to 2. Removed lines have a minus sign; added lines have a plus sign.
| Old | New | Line | |
|---|---|---|---|
| 1 | 1 | Является [[Keyword/ru|ключевым словом]], которое используется в управляющей конструкции аналогично циклу '[[While/ru|while]] [[Do/ru|do]]'. | |
| 2 | 2 | ||
| 3 | 3 | Синтаксис: | |
| 4 | 4 | ||
| 5 | - | ||
| 6 | - | ||
| 7 | - | ||
| 5 | + | ```text | |
| 6 | + | repeat | |
| 7 | + | <блок операторов> | |
| 8 | + | until <условие>; | |
| 9 | + | ``` | |
| 8 | 10 | ||
| 9 | 11 | \<блок операторов\>: одиночный оператор на языке pascal или блок операторов, заключенный в *begin-end*. | |
| 10 | 12 | ||
| 11 | 13 | \<условие\>: выражение, значение которого является типом boolean. | |
| 12 | 14 | ||
| 13 | 15 | Пример: | |
| 14 | 16 | ||
| 15 | - | ||
| 16 | - | ||
| 17 | - | ||
| 18 | - | ||
| 19 | - | ||
| 20 | - | ||
| 21 | - | ||
| 17 | + | ``` pascal | |
| 18 | + | x := 1; | |
| 19 | + | repeat | |
| 20 | + | begin | |
| 21 | + | DoSomethingHere(x); | |
| 22 | + | x := x + 1; | |
| 23 | + | end; | |
| 24 | + | until x = 10; | |
| 25 | + | ``` | |
| 22 | 26 | ||
| 23 | 27 | --- | |
| 24 | 28 | *From the Free Pascal wiki, page "Until/ru", as it stood on 2019-08-11 after a change by Useroflazarus, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's [[Licensing]] page. If you have concerns about this material, [message the admin](/wiki-contact).* |
