Description
CALCULATENI evaluates a mathematical expression and stores the output integer of the expression in another variable. If the output of the expression is a Float (a number with decimal places), then output will be forced into integer form and rounded off to the nearest whole number.
How to use this command
CALCULATENI command is for node level operations. It can be used in any node as an instruction, except for the root node.
It should not be used on the Arrows.
Let's take an example: CALCULATENI $output_variable "25 + 45"
Here, "$output_variable" is where the result of the expression "25 + 45" will be stored.
If you had a tree variable "$x1" which was previously initialized to 45, the above expression could have also been "25 + $x1"
Examples
- CALCULATENI $bid_submitted "$base_rate + $pricing_augmentation"
- CALCULATENI $max_lane_count "1000"
- CALCULATENI $variable2 "($x1+45)*45/23"