Any Alambik script is built out of a series of statements.
A statement can be an assignment, a function call, a loop, a conditional statement or even a statement that does nothing at all (an empty statement).
In addition, statements can be bundled into statement-groups by encapsulating several of them with curly braces.
A statement-group is considered to be a statement in its own right. All these various statement types will be described in this chapter.
One more thing: Operators (logical, mathematical, etc..) are statements too!
| The Alambik interpreter supports several different kinds
of conditional statements. In keeping with the general language philosophy,
such statements are implemented in the easiest and clearest way possible.
For example: "If X equals 1 then otherwise " would be scripted as: if (%x==1) "Increment X going from 1 to 30 ." for (%x=1 to 30) "Repeat until X equals 30 " Repeat() Here is the list of the decision and control instructions included with Alambik Script 4.0:
|
| |
|
The RETURN () statement is used to quit a procedure or to "return"
a value from a function. |
| |
||||||||||||||||||
|
| |
|||||||||
|
|||||||||
| |
||||||||||||
|
| |
|||||||||||||||||||||||||||
Note : To compare string variables, you can use the equals operator (==), but not the greater-than or lesser-than operators ">" or "<". |