Arithmetic Operators
The following arithmetic operators are available:
Operator | Operation Performed |
---|---|
- | arithmetic negation |
cos | cosine |
sin | sine |
tan | tangent |
acos | arccosine |
asin | arcsine |
atan | arctangent |
sqrt | square root |
ceil (x) | returns a double value representing the smallest integer that is greater than or equal to x. There is no error return. |
floor (x) | returns a floating-point value representing the largest integer that is less than or equal to x. There is no error return. |
fabs (x) | returns the absolute value of the floating point number (x) |
+ | addition |
- | subtraction |
* | multiplication |
/ | division (floating point) |
% | modulo |
^ | exponent (e.g., a ^ 2 squares the value of a) |
= | equal to |