Difference between revisions of "Inc/fr"
From Free Pascal wiki
Jump to navigationJump to searchm |
m (Fixed syntax highlighting) |
||
(One intermediate revision by one other user not shown) | |||
Line 7: | Line 7: | ||
Par exemple, en employant la procédure Inc(incrément), vous pouvez accroître de 1 la variable nommée a comme suit : | Par exemple, en employant la procédure Inc(incrément), vous pouvez accroître de 1 la variable nommée a comme suit : | ||
− | <syntaxhighlight> | + | <syntaxhighlight lang=pascal> |
inc( a ); | inc( a ); | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Line 13: | Line 13: | ||
Si vous voulez ajouter 2 (ou plus) : | Si vous voulez ajouter 2 (ou plus) : | ||
− | <syntaxhighlight> | + | <syntaxhighlight lang=pascal> |
inc( a, 2 ); | inc( a, 2 ); | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Line 24: | Line 24: | ||
* [[Dec/fr|Dec]] - Décrémente la valeur d'une variable entière. | * [[Dec/fr|Dec]] - Décrémente la valeur d'une variable entière. | ||
* Lien vers la documentation RTL : [[doc:/rtl/system/succ.html |succ]] - Retourne l'élément suivant pour un type ordinal. | * Lien vers la documentation RTL : [[doc:/rtl/system/succ.html |succ]] - Retourne l'élément suivant pour un type ordinal. | ||
− | * Instruction [[For/fr|For]] control_variable := start_point [[ | + | * Instruction [[For/fr|For]] control_variable := start_point [[To/fr|To]] end_point [[Do/fr|Do]]. |
Latest revision as of 11:48, 17 February 2020
│
English (en) │
suomi (fi) │
français (fr) │
русский (ru) │
Inc
Inc(incrément) est une procédure en programmation Pascal qui vous permet d'ajouter facilement 1 (ou une autre valeur) à une variable.
Par exemple, en employant la procédure Inc(incrément), vous pouvez accroître de 1 la variable nommée a comme suit :
inc( a );
Si vous voulez ajouter 2 (ou plus) :
inc( a, 2 );
La procédure Inc est incluse dans l'unité System.