Control structures

FOR

A for loop is a repetition control structure. A loop that needs to execute a specific number of times.

for ( init; condition; increment )
{
   statement(s);
}
IF
if (A == 5) {X = 1;}
if (A == 5) {X = 1;} else {X = 2;}
SWITCH
switch ( expression )
{
case constant1 : statement(s);break;
case constant2 : statement(s);break;
...
default : statement(s);
}
FUNCTION
function AddOne(X) { return (X + 1) }
PROCEDURE
procedure MyBlackCandlePlot(inputArray, name) { Plot( inputArray, name, colorBlack, styleCandle );  }