Math Core

Lesson 5.2 · Expressions

Order of operations

What is 2+3×42 + 3 \times 4? If you add first you get 20, but if you multiply first you get 14. Only one answer can be right, so mathematicians agreed on a set of rules called the order of operations. Everyone who follows them gets the same answer.

The rules

Order of operations

  1. Grouping symbols first: parentheses ( )(\,), brackets [ ][\,] and fraction bars. If groups are inside other groups, start with the innermost one.
  2. Exponents next.
  3. Multiplication and division, working from left to right.
  4. Addition and subtraction, working from left to right.

So 2+3×4=2+12=142 + 3 \times 4 = 2 + 12 = 14, because multiplication comes before addition.

Some people remember the order with the word PEMDAS: Parentheses, Exponents, Multiplication and Division, Addition and Subtraction. Just remember that M and D are a team, and so are A and S. Neither partner in a team goes first automatically. You do them in the order they appear, from left to right.

Common mistake

PEMDAS does not mean "always multiply before you divide" or "always add before you subtract."

In 20−6+420 - 6 + 4, the subtraction is on the left, so it goes first: 20−6+4=14+4=1820 - 6 + 4 = 14 + 4 = 18. Adding first would give 20−10=1020 - 10 = 10, which is wrong.

In 24÷4×224 \div 4 \times 2, the division is on the left: 24÷4×2=6×2=1224 \div 4 \times 2 = 6 \times 2 = 12, not 24÷8=324 \div 8 = 3.

Working step by step

Rewrite the expression after each step, doing only one kind of operation at a time. Lining up your work like this makes mistakes easy to spot.

Worked example: Multiplication, division and addition

Evaluate 18÷3+2×518 \div 3 + 2 \times 5.

18÷3+2×5=6+10divide and multiply, left to right=16add\begin{aligned} 18 \div 3 + 2 \times 5 &= 6 + 10 && \text{divide and multiply, left to right} \\ &= 16 && \text{add} \end{aligned}

Worked example: Parentheses and an exponent

Evaluate 4+(7−2)2×34 + (7 - 2)^2 \times 3.

4+(7−2)2×3=4+52×3parentheses=4+25×3exponent=4+75multiply=79add\begin{aligned} 4 + (7 - 2)^2 \times 3 &= 4 + 5^2 \times 3 && \text{parentheses} \\ &= 4 + 25 \times 3 && \text{exponent} \\ &= 4 + 75 && \text{multiply} \\ &= 79 && \text{add} \end{aligned}

Grouping inside grouping

When one group sits inside another, like parentheses inside brackets, start in the middle and work your way out.

Worked example: Brackets and parentheses

Evaluate 3[20−(2+4)×3]3[20 - (2 + 4) \times 3].

3[20−(2+4)×3]=3[20−6×3]innermost parentheses=3[20−18]multiply inside the brackets=3[2]subtract inside the brackets=6multiply\begin{aligned} 3[20 - (2 + 4) \times 3] &= 3[20 - 6 \times 3] && \text{innermost parentheses} \\ &= 3[20 - 18] && \text{multiply inside the brackets} \\ &= 3[2] && \text{subtract inside the brackets} \\ &= 6 && \text{multiply} \end{aligned}

A number written right next to a bracket or parenthesis means multiplication, so 3[2]=3×23[2] = 3 \times 2.

The fraction bar groups

A fraction bar means "divide," but it also acts like a grouping symbol. Work out the whole top and the whole bottom first, then divide.

Worked example: Using a fraction bar

Evaluate 5+3210−3\dfrac{5 + 3^2}{10 - 3}.

Top: 5+32=5+9=145 + 3^2 = 5 + 9 = 14. Bottom: 10−3=710 - 3 = 7. So the value is 147=2\dfrac{14}{7} = 2.

Tip

Your calculator follows the order of operations, but it can't see a fraction bar. To enter 5+3210−3\dfrac{5 + 3^2}{10 - 3}, type parentheses around the top and around the bottom: (5+32)÷(10−3)(5 + 3^2) \div (10 - 3).

Practice

Practice 1

Evaluate 6+4×56 + 4 \times 5.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 2

Evaluate 30−12−630 - 12 - 6.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 3

Which operation should you do first in 15−8÷2+115 - 8 \div 2 + 1?

Practice 4

Evaluate 36÷4×3−1236 \div 4 \times 3 - 12.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 5

Evaluate 2×(1+4)2+22 \times (1 + 4)^2 + 2.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 6

Evaluate 42+89−3\dfrac{4^2 + 8}{9 - 3}.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 7

Evaluate 4[15−(3+1)×2.5]4[15 - (3 + 1) \times 2.5].

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 8

Maya wrote 10−2×3=2410 - 2 \times 3 = 24. Where should she put parentheses to make her answer true?