Please enable JavaScript to view this site.

This Instruction allows the execution of a group of instructions to be repeated a defined number of times.

Syntax

for (init, cond, update)

init

Loop initialization expression, typically a variable assignment (optional, default 0)

cond

Boolean expression describing the stay condition within the FOR loop

update

Update expression, typically variable increment/decrement. (optional, default 1)

Validity

Rule, Task

Note

Contrary to what happens in C, in R3 the declaration of a variable inside the arguments of a for loop is not allowed. It is therefore necessary to declare the variable previously

 

  

Keyboard Navigation

F7 for caret browsing
Hold ALT and press letter

This Info: ALT+q
Page Header: ALT+h
Topic Header: ALT+t
Topic Body: ALT+b
Contents: ALT+c
Search: ALT+s
Exit Menu/Up: ESC