Break/fr: what changed
Revision 1 to 2. Removed lines have a minus sign; added lines have a plus sign.
| Old | New | Line | |
|---|---|---|---|
| 1 | 1 | Le mot réservé **break** est l'une des commandes de boucle, utilisée pour sortir d'une boucle prématurément.\ | |
| 2 | 2 | La commande **break** ne peut être employée qu'à l'intérieur d'une boucle et s'applique à la boucle englobante la plus imbriquée le cas échéant.\ | |
| 3 | - | ||
| 3 | + | ||
| 4 | 4 | Exemple:\ | |
| 5 | 5 | ||
| 6 | 6 | ``` pascal | |
| 7 | 7 | var | |
| 8 | 8 | intI: Integer; | |
| 9 | 9 | intA: Integer = 50; | |
| 10 | 10 | begin | |
| 11 | 11 | for intI := 20 to 200 do | |
| 12 | 12 | begin | |
| 13 | 13 | ... | |
| 14 | 14 | if intI = intA then break; // Si la condition est vérifiée, la boucle se termine | |
| 15 | 15 | ... | |
| 16 | 16 | end; | |
| 17 | 17 | end; | |
| 18 | 18 | ``` | |
| 19 | 19 | ||
| 20 | 20 | ## Voir aussi | |
| 21 | 21 | ||
| 22 | 22 | - [[Reserved words/fr|mots réservés]] | |
| 23 | - | ||
| 24 | - | ||
| 25 | 23 | ||
| 26 | 24 | --- | |
| 27 | 25 | *From the Free Pascal wiki, page "Break/fr", as it stood on 2020-01-17 after a change by Bart, 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).* |
