Order of operations
When calculations have more than one operation, we have to follow rules for the order of operations:
Step 1:
From left to right, do all multiplication and division.
$$100−20×3+5 = 100−60+5$$
Step 2:
From left to right, do all addition and subtraction.
$$100−60+5 = 45$$
However, if there are parentheses or other types of brackets, do all operations that lie inside them first:
$$ 70 + 36 ÷ (8 − 4) +1 =$$
$$= 70 + 36 ÷ 4 + 1 = $$
$$ =70 + 9 + 1 = 80 $$
The order of operations also applies while working inside parentheses:
$$8+(3+3×4) = 8+(3+12) $$
$$= 8+15 = 23$$
When you have parentheses inside brackets and braces (sometimes referred as nested parentheses), always work from the inside out. There are multiple types of brackets. The innermost parentheses/round brackets () are calculated first, followed by the brackets/box brackets [] that normally form the next layer, followed by braces/curly brackets {} that form a third layer outwards:
$$ {1 + [4 × (2 + 3) + 1]} ÷ 11 = $$
$$ = {1 + [4 × 5 + 1]} ÷ 11 = $$
$$ = {1 + [20 + 1]} ÷ 11 = $$
$$ = {1 + 21} ÷ 11 = 22 ÷ 11 = 2 $$