//New grammar for FOR cycles
//Based on C# FOR cycles: https://msdn.microsoft.com/cs-cz/library/ch45axte.aspx
//Example
r →000008= 0;
FOR(i = 0; i < 10; i = i+2) {
→000001TEXT(i);
r →000007= r+i;
}
//Steps:
//1. Initial variable is established
//2. Condition i < 10 is evaluated
//2.1 If is less than 10, the condition evaluates to TRUE and body of FOR is executed
//2.2 The value i is incremented by 2
//2.3 The loop returns to the start of step 2 to evaluate condition again
//3. If condition is greater or equal to 10, the condition evaluates to FALSE and exit the loop
//4. Variable ends with value which return FALSE in the condition. i = 10
//Every FOR statement defines initializer, condition and iterator.
//FOR(initializer; condition; iterator){
// body;
//}
//initializer - define variable and its first value
//condition - the condition for execution the FOR cycle. All type of conditions, including functions are allowed, icluding negative values
//iterator - any type of iterators for increasing the initialized value are possible, including all C# operators - X++, X--... are possible
//Old grammar for FOR cycles still works, but is it not recommended for future use
FOR(i, 0, 9) {
→000002TEXT(i);
}
http://designforms.net
Calculation
Layout 0
Layout 1
Layout 2
Layout 3
Layout 4
Layout 5