Function with Multiple Parameters Example

Functions can have multiple parameters:

ASSIGN/ADDANDDOUBLE=FUNCTION((A,B),2*(A+B))
Creates a function and assigns it to the variable ADDANDDOUBLE. The function takes two parameters, adds them together and then multiplies the result by 2.

ASSIGN/V2=ADDANDDOUBLE(4,5)
Assigns V2 the value 18. The parameters 4 and 5 are substituted into the expression portion of the function, thus becoming 2*(4+5).