Dart comes with many typical operators that work like many languages; this includes the following:
- +: This is for the addition of numbers.
- -: This is for subtraction.
- *: This is for multiplication.
- /: This is for division.
- ~/: This is for integer division. In Dart, any simple division with / results in a double value. To get only the integer part, you would need to make some kind of transformation (that is, type cast) in other programming languages; however, here, the integer division operator does this task.
- %: This is for modulo operations (the remainder of integer division).
- -expression: This is for negation (which reverses the sign of expression).
Some operators have different behavior depending on the left operand ...