## About this lesson

How to do basic math in Python.

## Exercise files

Download this lesson’s related exercise files.

Math Operators.docx199.4 KB Math Operators - Solution.docx

199.7 KB

## Quick reference

### Math Operators

Python makes math very easy to do.

### When to use

Any time you need to do math in Python, use these math operators.

### Instructions

Math operators in Python are pretty straight forward:

- + Add
- - Subtract
- * Multiply
- / Divide
- ** Exponents
- % Modulus

Pay attention to the order of operations.

Multiplication and division get executed before addition and subtraction; but anything inside parenthesis get's executed first.

### Hints & tips

- Math operators in Python work exactly as you think they should
- Remember your math order of operations!
- You can do math on numbers or on variables too

Lesson notes are only available for subscribers.