About

Number operators

Elementary

Number - Arithmetic (Function|Operation)

Addition (+)

<math>addend + addend = sum </math>

x=1
x+=1
print x
# 2

Subtraction (−)

<math>minuend − subtrahend = difference</math>

Subtraction (-)

Division (÷ / )

Division (/)

dividend ÷ divisor = quotient

Python:

>>> 3/2
1.5

Multiplication (×)

<math> multiplicand × multiplier = product </math>

Integer

Integer Division (Truncating)

Python:

>>> 3//2
1

Modulo

count_to = 1 + 2

Expo / Log

Exponentiation

Exponentiation is a mathematical operation involving two numbers, the base (b) and the exponent (n) (or index or power).

<math>base^{exponent} = power</math>

<math>b^n = power</math>

Exponentiation (**).

Logarithm

Mathematics - Logarithm Function (log)

<math> log_{base}(power) = exponent </math>

Increment/ decrement

  • ++: increment
  • decrement