Basic Arithmetic in Python
Arithmetic in Python
num1 = 3
num2 = 10
answer = num1/num2
print(answer)
# returns 0.3 <-- which is float data typeModulus:
print(10 % 3)
# retunrs 1 - i.e Remainder
# As opposed to division
print(10 / 3)
# returns 0.3Order of operations:
Last updated