the
param
of
factor
param
(
expression )
Factor and expression yield integer
s.
if param(1) is empty then answer ¬ "The first parameter is null."
The param
function returns a parameter value from the parameter list passed to the currently executing handler. The parameter returned is the nth parameter, where n is the integer
passed to the function. The value of param(0)
is the message name.
The following example sums the arguments passed to it, regardless of how many there are. In other words, it is functionally equivalent to the sum
function:
function addUp put 0 into total repeat with i = 1 to the paramCount add param(i) to total end repeat return total end addUp