Arithmetic Expression
Arithmetic expressions are simple mathematical calculations, where a numeric result is returned after the expression was evaluated. They may also be chained based on their order of precedence, where each item is one by one evaluated.
Besides arithmetic expression there are also operator modified assignment, which can be used similarly by directly assigning the result to a variable.
Syntax
Examples
Addition Operator
Minus Operator
Multiply Operator
Standard multiplications can be done between operands of the type num
.
Additionally, string repetitions can be also performed using the *
operator.