A symbol that performs a calculation or logical test on its operands, it can be arithmetic, comparison or boolean
Operand
The values that an operation applies to, e.g. in age > 18, both age and 18 are operands
+ Addition. This arithmetic operator sums operands, e.g. x + 4
- Subtraction, or taking away one operand from another is done by this arithmetic operation, e.g. health - 5
* Multiplication, the arithmetic operation that gives the product, or one operand times another, e.g. km * 2
/ Real division. The arithmetic operator that divides one operand by another e.g. total / 7
DIV
Also called integer division or floor division, the quotient arithmetic operator divides operands giving only the whole number result. E.g. 9 DIV 4 = 2. Python uses // for this.
MOD
The Modulus operator which gives the remainder after division, e.g. 9 MOD 4 = 1. Python uses % for this.
4
9 DIV 2
4.5
9 / 2
1
9 MOD 2
9
2 * 4 + 1
Remainder
The amount left over when one number is divided by another. Calculated with the MOD operator