Math Foundations

Order of Operations Explained

Why 2 + 3 × 4 equals 14, not 20: a clear guide to brackets, powers, multiplication, division, addition and subtraction, with worked examples and common errors.

On this page
  1. Why we need an agreed order
  2. The order
  3. Multiplication and division are equal partners
  4. Worked examples
  5. Hidden brackets
  6. Powers and negative numbers
  7. When the rules are not enough
  8. Why it matters beyond homework
  9. A habit that helps

Why we need an agreed order

Consider 2 + 3 × 4. If you work from left to right, you get 5 × 4 = 20. If you multiply first, you get 2 + 12 = 14. A written expression should have one correct value, so mathematicians agreed on a standard order of operations. By that convention, the answer is 14.

The order is not a deep truth about numbers. It is a shared set of rules, like the rule that we read English left to right. Because everyone follows the same rules, an expression means the same thing to everyone who reads it.

The order

Work through an expression in this sequence:

  1. Brackets (parentheses) first, working from the innermost pair outward.
  2. Powers (exponents, indices) and roots next.
  3. Multiplication and division, from left to right.
  4. Addition and subtraction, from left to right.

You may know this as BODMAS, BIDMAS or PEMDAS, depending on where you learned it. The mnemonics differ slightly but describe the same order. The phrase “from left to right” matters, and it is where many mistakes happen.

Multiplication and division are equal partners

A common misunderstanding is that multiplication always comes before division because M appears before D in the letters. It does not. They share the same level, and you handle them in the order they appear, from the left. The same applies to addition and subtraction.

Take 8 ÷ 2 × 4. Working left to right, 8 ÷ 2 = 4, then 4 × 4 = 16. If you did the multiplication first, you would get 8 ÷ 8 = 1, which is wrong under the convention.

Similarly, 10 − 4 − 3 is evaluated as (10 − 4) − 3 = 3. Doing the second subtraction first would give 10 − 1 = 9, which is not correct.

And 48 ÷ 6 × 2 is 8 × 2 = 16, not 48 ÷ 12 = 4.

Worked examples

Example 1: 7 + 2 × 5. No brackets or powers. Multiply first: 2 × 5 = 10. Then add: 7 + 10 = 17.

Example 2: (7 + 2) × 5. Brackets first: 9. Then 9 × 5 = 45. Notice how adding the brackets changes the answer from 17 to 45.

Example 3: 2 + 3² × 2. The power comes first: 3² = 9. Then multiplication: 9 × 2 = 18. Then addition: 2 + 18 = 20.

Example 4: 20 − 12 ÷ 4 + 1. Division first: 12 ÷ 4 = 3. Now 20 − 3 + 1, working left to right: 17 + 1 = 18.

Example 5: nested brackets, 2 × (3 + (4 − 1)²). Start with the innermost bracket: 4 − 1 = 3. Then the power: 3² = 9. Then the outer bracket: 3 + 9 = 12. Finally 2 × 12 = 24.

Hidden brackets

Some expressions have brackets that are not drawn. A fraction bar groups the top and the bottom. In (6 + 4) / (3 + 2), the top is 10 and the bottom is 5, giving 2. If you type this into a calculator and forget the brackets, you will calculate 6 + 4 ÷ 3 + 2, which is about 9.33. This is one of the most frequent errors when moving from paper to a device.

Likewise, a long division line, a square root sign over several terms, or a power with an expression in the exponent all act as brackets around what they cover.

Powers and negative numbers

A power applies only to what is directly attached to it. In 2 × 3², the power applies to the 3 only, so this is 2 × 9 = 18, not 6² = 36.

Negative numbers cause a subtle issue. By the usual convention, −3² means −(3²) = −9, because the power is done before the negation. If you want the square of negative three, write (−3)² = 9. Some calculators and software treat these differently, so it is worth checking how yours behaves and using brackets when in doubt.

When the rules are not enough

Expressions like 6 ÷ 2(1 + 2) circulate online as puzzles and cause arguments. The trouble is that the notation is ambiguous: some people treat 2(1 + 2) as a single unit, others do not. The standard rules, applied strictly left to right, give 6 ÷ 2 × 3 = 9, but the real lesson is that a well-written expression avoids the problem. If an expression could be read two ways, add brackets or rewrite it. Clear notation is more valuable than winning a debate about convention.

Why it matters beyond homework

The order of operations underlies algebra basics, where expressions such as 3n + 2 need to be evaluated correctly after substituting a value. It also matters in programming and spreadsheets, which follow similar precedence rules. In a spreadsheet, typing =2+3*4 gives 14. In Python, 2 + 3 * 4 also gives 14, and -3 ** 2 gives -9, in line with the convention above. If you are following python beginners material, you will meet these same rules.

When a formula gives a strange result, checking the order and adding brackets is often the quickest fix. That mindset of testing and narrowing down the error is part of a debugging mindset, whether in math or code.

A habit that helps

Before calculating, scan the expression and mark the order with light pencil numbers. Rewrite the expression after each step, so that only one operation changes at a time. Errors usually come from doing two steps at once, and writing each line out makes mistakes easier to find.

To practice, make up your own expressions, predict the answer and check it. Predicting first and checking afterward, rather than simply rereading the rules, tends to help the ideas stick, although the benefit varies between learners.

The complete guide to math foundations

Number Sense: The Foundation of Everyday Mathematics
Read the guide

Keep exploring

Guides from other topics

All topics →