The Order of Operations
Learn the agreed order for evaluating expressions, avoid the classic left-to-right trap, and see why calculators and spreadsheets follow the same rules.
Welcome back!
Step 1 of 14Learn
The puzzle that splits the internet
Every few months a puzzle goes viral: "What is 6 + 4 × 2?" Half the replies say 20, half say 14. Both groups are confident, and both have calculators to "prove" it.
The correct answer is 14. Math has an agreed order of operations so that everyone who reads an expression gets the same result. Without it, written math would be ambiguous, and spreadsheets, tax forms and engineering calculations would be chaos.
The order, often remembered as PEMDAS in the US (or BODMAS/BIDMAS in the UK and elsewhere):
- Parentheses (and other grouping symbols) first.
- Exponents, such as 32 = 9.
- Multiplication and Division, working left to right.
- Addition and Subtraction, working left to right.
So in 6 + 4 × 2, multiplication comes before addition: 4 × 2 = 8, then 6 + 8 = 14. The answer 20 comes from working strictly left to right, as if you were reading a sentence.
The key detail people forget is in steps 3 and 4. Multiplication does not always come before division, and addition does not always come before subtraction. They're partners of equal rank, done in the order they appear from left to right. "My Dear Aunt Sally" makes it sound like M beats D. It doesn't.
Step 2 of 14Practice · Work it out
Evaluate 6 + 4 × 2.
Step 3 of 14Compare
Two ways to read 6 + 4 × 2
| Aspect | Strict left to right | Order of operations |
|---|---|---|
| First move | 6 + 4 = 10 | 4 × 2 = 8 (multiply first) |
| Second move | 10 × 2 = 20 | 6 + 8 = 14 |
| Result | 20, the common wrong answer | 14, the agreed answer |
| Who works this way | Basic four-function calculators, reading like a sentence | Scientific calculators, phones in scientific mode, spreadsheets |
Step 4 of 14Learn
Working through longer expressions
Here's a longer one, step by step:
20 − 12 ÷ 4 × 2 + 32
Parentheses: none. Exponents: 32 = 9, giving 20 − 12 ÷ 4 × 2 + 9. Multiplication and division, left to right: 12 ÷ 4 = 3 first (it comes first), then 3 × 2 = 6. Now we have 20 − 6 + 9. Addition and subtraction, left to right: 20 − 6 = 14, then 14 + 9 = 23.
Notice the trap at the subtraction step. If you added first (6 + 9 = 15) and then subtracted (20 − 15), you'd get 5. Left to right matters.
Parentheses override everything. They let you force a different order: (6 + 4) × 2 = 20. If you want a result to be unambiguous, add parentheses even when they're not strictly needed. Spreadsheet users know this well: in Excel or Google Sheets, =A1+B1/2 divides only B1 by 2, while =(A1+B1)/2 gives the average.
Fraction bars act as grouping symbols too. In a fraction with (8 + 4) on top and (2 + 1) on the bottom, you evaluate the top and bottom separately first: 12 ÷ 3 = 4.
Basic four-function calculators often work left to right as you type, while scientific calculators and phone calculators in scientific mode follow the order of operations. If your answers don't match, that's usually why.
Step 5 of 14Practice · Put in order
Put the steps of the order of operations in the correct sequence.
Drag the items, or use the arrow buttons, to put them in order.
- Exponents
- Parentheses and other grouping symbols
- Multiplication and division, left to right
- Addition and subtraction, left to right
Step 6 of 14Practice · Work it out
Evaluate 18 ÷ 3 × 2.
Step 7 of 14Practice · Diagram
The order of operations as a pipeline
Every expression passes through the same four stations. Tap a station to see what happens there.
In 20 − 12 ÷ 4 × 2 + 9, at which station is 12 ÷ 4 × 2 worked out?
Tap the shape that answers the question, then press Check.
- Parentheses
Work out anything inside brackets, fraction bars or square roots first.
- Exponents
Powers such as 32 = 9, applied before any sign in front of them.
- Multiply and divide, left to right
Equal partners: whichever comes first, reading left to right, goes first.
- Add and subtract, left to right
Also equal partners. In 20 − 6 + 9, subtract first because it comes first.
Step 8 of 14Note
Step 9 of 14Practice · Spot the mistake
Rosa evaluated 10 − 2 × 3 + 4 like this. Tap the step where she went wrong.
Step 10 of 14Learn
Three traps that catch adults
Most order-of-operations errors come from the same three places.
Negative signs and exponents. As you'll see in the next lesson, −42 means −(42) = −16, because the exponent is applied before the minus sign. If you mean the square of negative four, write (−4)2 = 16. Spreadsheets follow the same rule, and a surprising number of financial models have broken on it.
Hidden grouping. Square roots, absolute value bars and fraction bars all group what's inside them. √(9 + 16) = √25 = 5, which is not the same as √9 + √16 = 3 + 4 = 7. When you type these into a calculator or spreadsheet, you must add the parentheses yourself: =SQRT(9+16), and =(8+4)/(2+1) for a fraction.
Long chains of division. 48 ÷ 4 ÷ 2 means (48 ÷ 4) ÷ 2 = 6, not 48 ÷ (4 ÷ 2) = 24. Left to right is the rule, and it matters most here.
Finally, beware of viral puzzles written as 8 ÷ 2(2 + 2). Mathematicians themselves disagree on whether implied multiplication, writing a number right against a parenthesis, binds more tightly than division. In real work, nobody writes expressions like that. The lesson isn't who's right; it's that clear writing uses enough parentheses that the question never comes up.
Step 11 of 14Flashcards
Trap or not? Flip to check
Tap a card to flip it.
Step 12 of 14Practice · True or false
In the expression 4 + 32, you should add 4 + 3 first and then square the result.
Step 13 of 14Practice · Choose one
A spreadsheet cell contains =10+20/5. What value does it show?
Step 14 of 14Practice · Work it out
Evaluate 2 × (5 + 3)2 − 10.
Lesson complete!