Perform basic arithmetic operations.
Add, subtract, multiply, divide two numbers:
<arithmetic-instruction> <numerical-variable> <numerical-value>
Compute the negative value of a numerical variable:
neg <numerical-variable>
Truncate value of a numerical variable to the nearest integer value
between that value and 0:
trunc <numerical-variable>
The <arithmetic-instruction> must be one of the following:
add
sub
mul
div
A <numerical-variable> must be the identifier of a variable whose
current value is a string representing a decimal integer or floating-point
number.
A <numerical-value> can be either a <numerical-variable>, or
a string representing a decimal integer or floating-point
number. The value resulting from the arithmetic computation
is stored into <numerical-variable>.
Arithmetic computation is always performed by Tefigel in floating-point
in decimal base representation.
[Previous chapter]
[Next chapter]
[Back to top]
|