Order of Operations (PEMDAS)

Four steps, two of them shared: parentheses, exponents, multiply-and-divide left to right, add-and-subtract left to right. Here's how it works — and the three traps that cause almost every wrong answer.

Parentheses

Do whatever is inside grouping symbols first — round brackets ( ), square brackets [ ], and the bar of a fraction all count.

Exponents

Powers and roots come next: 3² means 3 × 3 = 9.

Multiplication & Division

Equal rank, worked left to right — whichever appears first. Multiplication does not outrank division.

Addition & Subtraction

Also equal rank, also left to right. These always come last.

Download the PEMDAS chart (PDF) Download the practice worksheet (PDF)

A worked example, step by step

Take 5 + (8 − 3)² × 2 ÷ 5 and walk the ladder top to bottom:

StepExpressionWhat happened
Parentheses5 + (8 − 3)² × 2 ÷ 5  →  5 + 5² × 2 ÷ 58 − 3 = 5
Exponents5 + 5² × 2 ÷ 5  →  5 + 25 × 2 ÷ 55² = 25
Multiply (leftmost first)5 + 25 × 2 ÷ 5  →  5 + 50 ÷ 525 × 2 = 50
Divide5 + 50 ÷ 5  →  5 + 1050 ÷ 5 = 10
Add5 + 10 = 15done

Notice the multiplication and division were handled as one left-to-right sweep — we multiplied first only because it appeared first, not because M comes before D in the acronym.

The three traps that cause almost every wrong answer

1. Treating M as “before” D

8 ÷ 2 × 4 = 16, not 1. Multiplication and division are the same rank; you sweep left to right. Reading PEMDAS as “multiply, then divide” gives 8 ÷ 8 = 1 — the single most common order-of-operations mistake (it’s the engine behind every viral “only 1% get this right” math post).

2. Treating A as “before” S

10 − 4 + 3 = 9, not 3. Same rule, bottom rung: addition and subtraction sweep left to right. Adding first (4 + 3 = 7, then 10 − 7) silently regroups the expression.

3. The exponent-and-minus-sign trap

−3² = −9, but (−3)² = 9. An exponent binds before a leading minus sign, so −3² means −(3 × 3). If the negative number itself should be squared, it needs its own parentheses. This one matters constantly in pre-algebra.

PEMDAS, BODMAS, GEMS — same rules, different mnemonics

Depending on where and when you went to school you may have learned PEMDAS (“Please Excuse My Dear Aunt Sally”), BODMAS (Brackets, Orders, Division/Multiplication, Addition/Subtraction — common in the UK and India), or GEMS (Groupings, Exponents, Multiply/divide, Subtract/add). They describe the same mathematics. BODMAS putting D before M changes nothing — because that middle rung is always one left-to-right sweep, whatever order the letters imply.

Try five — answers hidden until you click

3 + 6 × 5 − 6 = ?

Multiply first: 6 × 5 = 30. Then left to right: 3 + 30 = 33, 33 − 6 = 27.

36 ÷ 6 × 2 = ?

Trap #1! Left to right: 36 ÷ 6 = 6, then 6 × 2 = 12 (not 3).

(5 + 4) × (7 − 1) = ?

Both parentheses first: 9 × 6 = 54.

2³ + 4 × 5 = ?

Exponent first: 2³ = 8. Multiply: 4 × 5 = 20. Add: 28.

20 − 12 ÷ (2 + 2) = ?

Parentheses: 2 + 2 = 4. Divide: 12 ÷ 4 = 3. Subtract: 20 − 3 = 17.

Rules are easy — speed takes practice.

Num Drill’s pre-algebra levels mix order-of-operations expressions with solve-for-x problems and adapt to whatever your child misses. Free, no login, about a minute per quiz.

Start a free quiz See the pre-algebra levels

How to teach it (without the tears)

Common questions

What is the order of operations?

The order of operations is the agreed sequence for evaluating a math expression: grouping symbols (parentheses) first, then exponents, then multiplication and division together in one left-to-right pass, then addition and subtraction together in one left-to-right pass. It exists so any expression has exactly one correct value.

What does PEMDAS stand for?

Parentheses, Exponents, Multiplication, Division, Addition, Subtraction — often remembered as 'Please Excuse My Dear Aunt Sally'. Crucially, M and D are the same step worked left to right, and so are A and S; PEMDAS is four steps, not six.

Is PEMDAS the same as BODMAS?

Yes. BODMAS (Brackets, Orders, Division, Multiplication, Addition, Subtraction) is the UK/India mnemonic for the identical rules. BODMAS listing division before multiplication changes nothing, because that step is always a single left-to-right sweep.

Do you multiply before dividing in PEMDAS?

No. Multiplication and division have equal priority and are done left to right, whichever comes first. 8 ÷ 2 × 4 is 16 (divide first, because it appears first), not 1. The same left-to-right rule applies to addition and subtraction.

What grade do students learn the order of operations?

In most U.S. curricula the order of operations is introduced in 5th grade (parentheses and brackets) and consolidated in 6th grade, when exponents and negative numbers join. It stays essential through algebra and beyond.

Why does −3² equal −9 and not 9?

Because an exponent binds more tightly than a leading minus sign: −3² means −(3 × 3) = −9. To square the negative number itself, write (−3)², which is 9. On calculators and in code the same rule applies.


Related: pre-algebra practice · solve for x · 6th grade math · 5th grade math · printable worksheets · multiplication chart