expression1 + expression2 or expression1 - expression2 or expression1 * expression2 or expression1 / expression2 or expression1 % expression2
where:
These arithmetical operators are the same as in usual languages:
+
-
*
/
%
The operators will work with numbers values only.
There is an exception to the above rule.
The +
operator, is used to concatenate strings as well.
If on one side of +
is a string and
on the other side of +
is a numerical value,
then it will convert the numerical value to string
(using the format appropriate for language of the page) and then use the +
as string concatenation operator.
a + b a * b