Order of Operations

In mathematics, operations refer to actions like addition, subtraction, multiplication, division, and exponentiation. The same expression can produce different results depending on the order in which these operations are performed. The order of operations is a set of conventions that specifies a single, unambiguous evaluation order, ensuring that every mathematician and every calculator reads an expression the same way.

Quick Reference: The Rules

Priority Operation Notes
1 Parentheses (brackets) Innermost first
2 Exponentiation Right to left for stacked powers
3 Multiplication and Division Left to right, equal priority
4 Addition and Subtraction Left to right, equal priority

The Four Rules (PEMDAS)

The order of operations is captured by the mnemonic PEMDAS:

PEMDAS: Parentheses · Exponents · Multiplication & Division · Addition & Subtraction

A common memory phrase is "Please Excuse My Dear Aunt Sally." The four levels, in order of priority, are explained below.

Rule 1: Parentheses

Evaluate all expressions inside grouping symbols first, starting with the innermost group and working outward. Grouping symbols are the override mechanism: they always take priority, regardless of any other rule.

The P in PEMDAS stands for parentheses ( ), but the same rule applies to all three types of grouping symbol:

Symbol Name Typical use
( ) Parentheses Primary grouping
[ ] Brackets (square brackets) Grouping inside parentheses to improve readability
{ } Curly braces (braces) Outermost grouping when brackets are already in use

When expressions are nested, the convention in textbooks and handwriting is to alternate symbols from inside out (parentheses innermost, then brackets, then curly braces) so that the eye can easily match each opening symbol to its closing partner:

{ 2 × [ 3 + ( 4 1 ) ] } ÷ 3 = { 2 × [ 3 + 3 ] } ÷ 3 = { 2 × 6 } ÷ 3 = 12 ÷ 3 = 4.

Mathematically all three symbols mean exactly the same thing: evaluate the enclosed expression first. The alternation is a readability convention, not a rule that changes priority.

A basic example without nesting:

2 × ( 3 + 4 ) = 2 × 7 = 14 , ( 2 × 3 ) + 4 = 10.

Rule 2: Exponentiation

Apply exponents (powers and roots) before multiplication, division, addition, or subtraction.

2 + 3 2 = 2 + 9 = 11 , not ( 2 + 3 ) 2 = 25.

Rule 3: Multiplication and Division (left to right)

Multiplication and division have equal priority and are evaluated strictly left to right.

12 ÷ 4 × 3 = ( 12 ÷ 4 ) × 3 = 3 × 3 = 9 , not 12 ÷ ( 4 × 3 ) = 1.

Rule 4: Addition and Subtraction (left to right)

Addition and subtraction have equal priority and are evaluated strictly left to right.

7 3 + 2 = ( 7 3 ) + 2 = 4 + 2 = 6 , not 7 ( 3 + 2 ) = 2.

Why This Order? The Motivation Behind the Rules

The order of operations is a convention, not a mathematical law, but it is a well-motivated one. Each level of priority reflects how algebraic notation naturally groups quantities.

Why multiplication before addition? In algebra, writing 2 x + 3 means ( 2 x ) + 3 , never 2 ( x + 3 ) . The product 2 x is a single entity (a term), and terms are added together to form an expression. This intuition, embedded in algebraic notation since the 17th century, is why multiplication binds more tightly than addition.

Why exponentiation before multiplication? Similarly, 2 x 2 means 2 ( x 2 ) , not ( 2 x ) 2 . The exponent belongs to the base immediately below it. If multiplication had higher priority than exponentiation, standard polynomial notation would be unreadable.

Why left to right for equal-priority operations? This is a pure convention, consistent with the left-to-right direction of written language. It resolves ambiguity when two operations of equal strength appear in sequence.

Historical note. The rules were progressively formalized through the 16th–19th centuries as algebraic notation developed. The convention that multiplication precedes addition was implicit in Leibniz and Euler's notation. The explicit term "order of operations" and the classroom mnemonics (PEMDAS, BODMAS) were largely codified by textbook authors in the late 19th century, as mass-printed mathematics textbooks became widespread.

Worked Examples

Example 1. Evaluate 1 + 2 × 3 .

Multiplication before addition:

1 + 2 × 3 = 1 + 6 = 7.

Example 2. Evaluate 6 ÷ 2 × 3 .

Division and multiplication left to right:

6 ÷ 2 × 3 = ( 6 ÷ 2 ) × 3 = 3 × 3 = 9.

Example 3. Evaluate 2 + 3 2 × 4 ( 1 + 5 ) .

Parentheses → exponent → multiplication → addition/subtraction left to right:

\begin{aligned} 2 + 3^{2}\times4-(1+5) &= 2+9\times4-6 \\ &= 2+36-6 \\ &= 32. \end{aligned}

Example 4. Evaluate 3 + 5 2 3 2 × 3 .

The fraction bar acts as an implicit parenthesis around the numerator and denominator:

3 + 5 2 3 2 × 3 = 8 8 6 = 8 2 = 4.

Why Mnemonics Can Mislead

Mnemonic acronyms are useful memory aids, but they obscure two critical facts that are not spelled out by the letters themselves.

Pitfall 1: M and D are equal, not sequential. Because "M" appears before "D" in PEMDAS, many students conclude that multiplication is always performed before division. This is wrong. Multiplication and division share the same priority level and are evaluated left to right. Applying multiplication first gives incorrect results:

\begin{aligned} &6 \div 2 \times 3 \overset{\color{red}\text{wrong}}{=} 6\div6=1\\ &6\div2\times3\overset{\color{blue}\text{correct}}{=}(6\div2)\times3=9. \end{aligned}

Pitfall 2: A and S are equal, not sequential. Similarly, "A" before "S" does not mean addition is always done first. Addition and subtraction share equal priority and run left to right:

\begin{aligned} &2-3+4\overset{\color{red}\text{wrong}}{=}2-(3+4)=2-7=-5 \\ &2-3+4\overset{\color{blue}\text{correct}}{=}(2-3)+4=-1+4=3. \end{aligned}

Understanding the two-tier structure (multiplication and division together at level 3; addition and subtraction together at level 4) matters far more than remembering the letters.

Special Cases and Exceptions

Stacked Exponentiation (right to left)

When exponents are written as a tower (stacked superscripts), the convention is to evaluate from the top down, that is, right to left:

a b c = a ( b c ) .

This convention is both standard and natural: evaluating left to right would give ( a b ) c = a b c , which is just a single exponent and makes the tower notation pointless. For example:

3 2 4 = 3 16 = 43,046,721 , whereas ( 3 2 ) 4 = 9 4 = 6,561.

Implied Multiplication (Juxtaposition)

When multiplication is indicated by placing two quantities side by side, without any multiplication symbol, it is called implied multiplication or multiplication by juxtaposition. In academic and scientific writing, juxtaposition is conventionally given higher priority than explicit multiplication or division, because the two factors form a visual unit.

Under this convention, 1 / 2 n is read as 1 / ( 2 n ) , not as ( 1 / 2 ) n , and a / b c means a / ( b c ) .

This convention is not universal, however, and is a common source of confusion:

  • Many scientific calculators (TI-83, most HP models) treat 1 / 2 n as ( 1 / 2 ) n , giving priority to left-to-right division.
  • The TI-82 and some others do give juxtaposition higher priority.
  • Google and Wolfram Alpha follow strict left-to-right PEMDAS with no special treatment for juxtaposition.

Because of this disagreement, expressions like a / b c should always be avoided in writing. Use explicit parentheses, such as a / ( b c ) or ( a / b ) c , to remove any ambiguity.

Unary Minus

The minus sign can be either binary (between two numbers, meaning subtraction) or unary (in front of one number, meaning negation). The unary minus is generally treated as having lower priority than exponentiation, so:

3 2 = ( 3 2 ) = 9 , not ( 3 ) 2 = 9.

When negating the base is intended, explicit parentheses are required.

Ambiguous Expressions: The Viral Math Problem

In 2019, the expression 8 ÷ 2 ( 2 + 2 ) went viral online, with people arriving at two different answers:

  • Answer 16: Treat 2 ( 2 + 2 ) as 2 × ( 2 + 2 ) , then apply left-to-right PEMDAS: 8 ÷ 2 × 4 = 4 × 4 = 16 .
  • Answer 1: Treat 2 ( 2 + 2 ) as an implied-multiplication unit with higher priority: 8 ÷ [ 2 ( 4 ) ] = 8 ÷ 8 = 1 .

Both answers follow a consistent rule; they just follow different rules. The expression is genuinely ambiguous, and the disagreement it caused illustrates why professional mathematicians and scientists avoid this style of writing entirely. The American Mathematical Society commented that the problem is "ambiguous as written."

The correct takeaway is not which answer is right, but that a well-written expression leaves no room for ambiguity. The two unambiguous ways to write this problem are:

8 2 × ( 2 + 2 ) = 16 or 8 2 ( 2 + 2 ) = 1.

International Variants

PEMDAS is the standard mnemonic in the United States. Other English-speaking countries use different acronyms for the same rules:

Acronym Stands for Used in
BODMAS Brackets, Order, Division/Multiplication, Addition/Subtraction UK, India, Australia
BEDMAS Brackets, Exponents, Division/Multiplication, Addition/Subtraction Canada, New Zealand
BIDMAS Brackets, Indices, Division/Multiplication, Addition/Subtraction UK (alternative)

Despite the different names, the mathematical rules are identical. The differences are purely linguistic (parentheses vs. brackets, exponents vs. orders vs. indices), reflecting regional English vocabulary rather than different mathematics.

Exercises

Exercise 1.

Evaluate each expression.

(a) 4 + 5 × 2    (b) 20 ÷ 5 × 2    (c) 10 4 + 3    (d) 3 + 2 3 × 2

Answer

(a) 14   (b) 8   (c) 9   (d) 19

Solution

Work down the priority ladder each time, doing the highest-priority operation present before anything else.

TikZ figure

(a) 4 + 5 × 2 . The expression contains an addition and a multiplication. Multiplication sits at level 3 and addition at level 4, so the multiplication goes first:

5 × 2 = 10 , 4 + 10 = 14.

Doing the addition first would give 9 × 2 = 18 , which is wrong.

(b) 20 ÷ 5 × 2 . Division and multiplication are both at level 3, so they have equal priority and we work strictly left to right. Reading from the left, the division comes first:

20 ÷ 5 = 4 , 4 × 2 = 8.

This is the pitfall the section warns about. The "M" before the "D" in PEMDAS does not mean multiplication goes first. Doing the multiplication first would give 20 ÷ 10 = 2 , which is wrong.

(c) 10 4 + 3 . Addition and subtraction are both at level 4, so again we go strictly left to right, and the subtraction comes first:

10 4 = 6 , 6 + 3 = 9.

Doing the addition first would give 10 7 = 3 , which is wrong.

(d) 3 + 2 3 × 2 . Three levels appear here. The exponent is at level 2, so it goes first:

2 3 = 8.

The expression is now 3 + 8 × 2 . Multiplication (level 3) beats addition (level 4):

8 × 2 = 16 , 3 + 16 = 19.

A common wrong route is to multiply the 2 and the 2 first, getting 3 + 4 3 . The exponent belongs to the 2 immediately beneath it, not to any later product.

Exercise 2.

Evaluate { 12 [ 5 ( 3 1 ) ] } × 2 .

Answer

18

Solution

This section says that when grouping symbols are nested, we start with the innermost group and work outward. Think of it as peeling an onion one layer at a time.

TikZ figure

Step 1: the innermost group. The parentheses ( 3 1 ) are inside everything else, so they go first:

3 1 = 2.

The expression becomes

{ 12 [ 5 2 ] } × 2.

Step 2: the next layer out. Now the square brackets are innermost:

5 2 = 3.

The expression becomes

{ 12 3 } × 2.

Step 3: the outermost group. Evaluate the curly braces:

12 3 = 9.

The expression becomes

9 × 2.

Step 4: what is left. Only the multiplication remains:

9 × 2 = 18.

A note on the three symbols. As this section explains, (   ) , [   ] and {   } mean exactly the same thing mathematically. Alternating them is purely so that the eye can pair each opening symbol with its closing one. So do not imagine that curly braces are somehow "more powerful" than parentheses; here the parentheses were done first simply because they were innermost.

The mistake to avoid. Working from the outside in, or subtracting left to right across the brackets, would give { 12 5 2 } × 2 = 5 × 2 = 10 . The brackets exist precisely to prevent that reading.

Exercise 3.

Evaluate 4 + 6 × 2 5 2 3 × 7 .

Answer

4

Solution

As this section explains, the fraction bar acts as an implicit parenthesis around the whole numerator and around the whole denominator. So the correct plan is: evaluate the top completely, evaluate the bottom completely, then divide.

The numerator, 4 + 6 × 2 . Multiplication before addition:

6 × 2 = 12 , 4 + 12 = 16.

The denominator, 5 2 3 × 7 . The exponent is at level 2, so it goes first:

5 2 = 25.

Then the multiplication, at level 3:

3 × 7 = 21.

Then the subtraction, at level 4:

25 21 = 4.

The division. Now, and only now, do we divide:

16 4 = 4.

Why the implicit parentheses matter. If this expression were typed on one line without brackets, as 4 + 6 × 2 ÷ 5 2 3 × 7 , the rules would give something entirely different — the division would apply only to the 12 , not to the whole of 16 . To type the original safely you would have to write

( 4 + 6 × 2 ) ÷ ( 5 2 3 × 7 ) .

This is worth remembering whenever you copy a printed fraction into a calculator: the bar has to be replaced by brackets, or the answer will be wrong.

Exercise 4.

Evaluate each of the following, and comment on any pair that gives the same value.

(a) 4 2    (b) ( 4 ) 2    (c) 2 3    (d) ( 2 ) 3

Answer

(a) 16   (b) 16   (c) 8   (d) 8

Solution

This section states that exponentiation has higher priority than a unary minus — that is, than a minus sign used to negate a single quantity. So without brackets, the power is applied first and the minus sign is applied last.

(a) 4 2 . There are no brackets, so the exponent binds to the 4 alone:

4 2 = ( 4 2 ) = ( 16 ) = 16.

(b) ( 4 ) 2 . The brackets override the usual priority, exactly as the section says grouping symbols always do. Now the base really is 4 :

( 4 ) 2 = ( 4 ) × ( 4 ) = 16.

Parts (a) and (b) differ in sign, and the only difference between them is a pair of brackets. This is one of the most frequently mishandled pieces of notation in all of algebra.

(c) 2 3 . Again no brackets, so the cube applies to the 2 alone:

2 3 = ( 2 3 ) = ( 8 ) = 8.

(d) ( 2 ) 3 . Here the base is 2 :

( 2 ) 3 = ( 2 ) × ( 2 ) × ( 2 ) = 4 × ( 2 ) = 8.

The pair that agrees. Parts (c) and (d) both give 8 , even though the brackets differ. The reason is that the exponent is odd. Cubing 2 leaves one minus sign without a partner, so the result is negative anyway — which is the same sign that the external minus produces in (c).

For an even exponent the two disagree, as (a) and (b) show, because the minus signs cancel in pairs inside the bracket.

The practical advice. Because 4 2 and ( 4 ) 2 look so alike and mean such different things, always write the brackets when you intend to square a negative number. And when reading someone else's expression, check for the brackets before assuming which is meant.

Exercise 5.

Evaluate 2 3 2 and ( 2 3 ) 2 , and say which is larger.

Answer

2 3 2 = 512 and ( 2 3 ) 2 = 64 ; the first is larger.

Solution

Evaluating 2 3 2 . This is a tower of exponents, and this section states that towers are evaluated from the top down, that is, right to left:

a b c = a ( b c ) .

So the top pair is dealt with first:

3 2 = 9.

The expression becomes

2 9 = 512.

(Doubling nine times: 2 , 4 , 8 , 16 , 32 , 64 , 128 , 256 , 512 .)

Evaluating ( 2 3 ) 2 . Here the brackets tell us plainly what to do first:

2 3 = 8 , 8 2 = 64.

Alternatively, by the Power of a Power Rule from the earlier section on exponents, ( 2 3 ) 2 = 2 3 × 2 = 2 6 = 64 , which agrees.

Which is larger. Since 512 > 64 , the tower 2 3 2 is much the larger — eight times larger, in fact.

Why the top-down convention exists. This section gives the reason, and it is a good one. If a tower were read from the bottom up, then a b c would mean ( a b ) c , which by the Power of a Power Rule is just a b c — an ordinary single exponent. The stacked notation would then be pointless, since it would never express anything new. Reading top-down is what makes towers worth writing at all.

A caution about calculators. Some calculators and programming languages evaluate a chain of powers left to right, so entering 2^3^2 may return 64 rather than 512 . When in doubt, insert brackets and write 2 ( 3 2 ) explicitly.

Exercise 6.

Insert one pair of parentheses in each expression to make the statement true.

(a) 2 + 3 × 4 = 20    (b) 12 4 ÷ 2 = 4    (c) 5 + 3 2 = 64

Answer

(a) ( 2 + 3 ) × 4 = 20   (b) ( 12 4 ) ÷ 2 = 4   (c) ( 5 + 3 ) 2 = 64

Solution

These run the usual exercises backwards: instead of applying the rules, we use brackets to override them and force a different order. Recall that grouping symbols always take priority, whatever the other rules say.

A good method is to first work out what the expression gives without brackets, see how far off it is, and then ask which operation would have to be promoted.

(a) 2 + 3 × 4 = 20 . Without brackets the rules give 2 + 12 = 14 , not 20 . To reach 20 we notice 20 = 5 × 4 , and 5 is 2 + 3 . So the addition must be done first, which means bracketing it:

( 2 + 3 ) × 4 = 5 × 4 = 20.

(b) 12 4 ÷ 2 = 4 . Without brackets the rules give 12 2 = 10 , not 4 . To reach 4 we notice 4 = 8 ÷ 2 , and 8 is 12 4 . So the subtraction must be promoted:

( 12 4 ) ÷ 2 = 8 ÷ 2 = 4.

(c) 5 + 3 2 = 64 . Without brackets the rules give 5 + 9 = 14 , not 64 . To reach 64 we notice 64 = 8 2 , and 8 is 5 + 3 . So the addition must be done before the squaring:

( 5 + 3 ) 2 = 8 2 = 64.

The pattern. In all three parts the bracket promoted the operation that the rules would otherwise have done last. That is the usual situation, because brackets are only needed when you want the natural order reversed. If the answer you want already matches the unbracketed value, no brackets are required at all.

Always check. After inserting brackets, evaluate the whole expression from scratch and confirm you reach the stated value, as done above. It is easy to bracket the right numbers in the wrong place.

Exercise 7.

A shop sells shirts at $12 each and hats at $ 7 each. Priya buys 3 shirts and 2 hats, then uses a $ 5 voucher.

(a) Write a single expression for the amount she pays.

(b) Evaluate it.

(c) Her friend evaluates the expression strictly left to right and gets a different answer. What does he get, and why is it wrong?

Answer

(a) 3 × 12 + 2 × 7 5    (b) $ 45    (c) 261

Solution

Part (a). The cost of the shirts is 3 lots of $ 12 , that is 3 × 12 . The cost of the hats is 2 lots of $7"> ___RAW_PRESERVED_4___7 , that is 2 × 7 . These are added, and then the voucher is subtracted:

3 × 12 + 2 × 7 5.

Notice that no brackets are needed. The order of operations already does the right thing, because each product is a single item of cost — a term — and the terms are then added and subtracted. This is exactly the motivation this section gives for putting multiplication above addition in the first place.

Part (b). Multiplications first, since they sit at level 3:

3 × 12 = 36 , 2 × 7 = 14.

The expression becomes

36 + 14 5.

Addition and subtraction share level 4, so work left to right:

36 + 14 = 50 , 50 5 = 45.

So Priya pays $ 45 .

Check against the story: three shirts at $ 12 is $36"> ___RAW_PRESERVED_5___36 ; two hats at $7"> ___RAW_PRESERVED_6___7 is $14"> ___RAW_PRESERVED_7___14 ; together $50"> ___RAW_PRESERVED_8___50 ; less the $5"> ___RAW_PRESERVED_9___5 voucher leaves $45"> ___RAW_PRESERVED_10___45 . ✓

Part (c). Evaluating strictly left to right, ignoring priority, the friend would compute

3 × 12 = 36 , 36 + 2 = 38 , 38 × 7 = 266 , 266 5 = 261.

So he gets 261 . The answer is absurd on its face: Priya bought five items whose listed prices are $ 12 and $7"> ___RAW_PRESERVED_11___7 , so she cannot possibly owe more than about $60"> ___RAW_PRESERVED_12___60 .

The mistake is that " + 2 " was treated as a step in a running total, when in fact the 2 is not an amount of money at all — it is a count of hats, and it only becomes money once multiplied by 7 . The order of operations exists precisely so that 2 × 7 is bound together as one quantity before any adding happens.

The general lesson. When a real situation is written as a single expression, the order of operations usually matches the meaning automatically. If your arithmetic gives an answer that makes no sense in the story, suspect the order before suspecting the arithmetic.

Exercise 8.

Evaluate 24 ÷ 6 ÷ 2 and 24 ÷ ( 6 ÷ 2 ) . Explain why they differ.

Answer

24 ÷ 6 ÷ 2 = 2 and 24 ÷ ( 6 ÷ 2 ) = 8 .

Solution

The first expression, 24 ÷ 6 ÷ 2 . Both operations are divisions, sitting at the same priority level, so the rule is strictly left to right:

24 ÷ 6 = 4 , 4 ÷ 2 = 2.

So the value is 2 .

The second expression, 24 ÷ ( 6 ÷ 2 ) . The brackets override the left-to-right rule and force the second division to happen first:

6 ÷ 2 = 3 , 24 ÷ 3 = 8.

So the value is 8 .

Why they differ. Division is not associative: regrouping the same numbers with the same operations changes the answer. Compare this with addition, where the associative property from the earlier section on the rules of algebra guarantees a + ( b + c ) = ( a + b ) + c , so the grouping makes no difference. There is no such guarantee for division.

This is exactly why the left-to-right convention is needed. With addition the convention would be harmless, since every grouping agrees. With division the convention is doing real work: it picks out one of two genuinely different answers as the meaning of 24 ÷ 6 ÷ 2 .

A related warning. Subtraction is not associative either, for the same reason. This section illustrates it with

7 3 + 2 = 6 but 7 ( 3 + 2 ) = 2.

Practical advice. A chain of divisions such as a ÷ b ÷ c is easy to misread. If you mean a b c , write it that way, or write a ÷ ( b × c ) . If you mean a b ÷ c , use a bracket or a fraction bar. The reader should never have to rely on remembering a convention.

Exercise 9.

Evaluate 16 + | 3 7 | × 2 2 .

Answer

20

Solution

Two extra symbols appear here, and each behaves as a grouping symbol in its own way.

  • A radical sign acts like a bracket around everything underneath it: evaluate what is inside first, then take the root. The root itself sits at level 2, alongside exponents, since a root is a fractional exponent.
  • Absolute value bars likewise act like brackets: evaluate what is inside first, then take the absolute value.

Step 1: the grouped quantities. Inside the absolute value bars,

3 7 = 4 ,

so

| 3 7 | = | 4 | = 4 ,

using the definition from the earlier section: the absolute value of a negative number is its negative, and ( 4 ) = 4 . The answer is positive, as an absolute value always is.

The radical needs no inner work, since 16 is already a single number.

Step 2: level 2, roots and exponents.

16 = 4 because  4 2 = 16 , 2 2 = 4.

The expression is now

4 + 4 × 4.

Step 3: level 3, multiplication.

4 × 4 = 16.

The expression is now

4 + 16.

Step 4: level 4, addition.

4 + 16 = 20.

The mistake to guard against. It is tempting to read the middle of the expression as 4 + 4 first, giving 8 × 4 = 32 . But the multiplication outranks the addition, so the 4 from the square root has to wait. Writing each stage on its own line, as above, makes it much harder to slip.

Note also that | 3 7 | is 4 , not 4 and not 3 7 . The bars must be evaluated, not simply erased.

Exercise 10.

A student evaluates 18 ÷ 3 × 2 as 18 ÷ 6 = 3 . Find the error and give the correct value.

Answer

The correct value is 12 .

Solution

The correct value. Division and multiplication have equal priority, so they are performed strictly left to right. Reading from the left, the division comes first:

18 ÷ 3 = 6 , 6 × 2 = 12.

The error. The student performed the multiplication 3 × 2 before the division, almost certainly because the letter "M" comes before the letter "D" in PEMDAS. But as this section stresses, "MD" is a single level, not two. The letters appear in that order only because the acronym has to be pronounceable.

There is a second way to describe the same mistake: the student effectively read the expression as 18 ÷ ( 3 × 2 ) , inserting a bracket that is not there. Brackets change the meaning, and you are not free to add them.

Checking which reading is right. Rewrite the expression as a fraction. Left to right, 18 ÷ 3 × 2 means

18 3 × 2 = 6 × 2 = 12 ,

whereas the student's reading would have to be written as

18 3 × 2 = 18 6 = 3.

These are visibly different expressions, and only the first matches what was written.

How to avoid this. When you see a run of multiplications and divisions, put your finger at the left end and move right, doing each operation as you meet it. Do not scan ahead for multiplications. The same discipline applies to a run of additions and subtractions.

Exercise 11.

A student evaluates 10 2 3 as 10 ( 2 3 ) = 10 ( 1 ) = 11 . Find the error and give the correct value.

Answer

The correct value is 5 .

Solution

The correct value. Both operations are subtractions, at the same priority level, so they are performed strictly left to right:

10 2 = 8 , 8 3 = 5.

The error. The student grouped the last two numbers together, inserting a bracket that was never written. As noted in the previous exercise, adding a bracket changes the expression into a different one.

The damage is done by the sign. Inside the invented bracket, 2 3 = 1 , and subtracting 1 adds 1 rather than removing 3 . That is why the student's answer, 11 , is not merely different but larger than the number he started with — a clear signal that something has gone wrong, since we are subtracting positive amounts from 10 and the result must be smaller than 10 .

A concrete check. Think of it as money: you have $ 10 , you spend $2"> ___RAW_PRESERVED_13___2 , then you spend $3"> ___RAW_PRESERVED_14___3 . You are left with $5"> ___RAW_PRESERVED_15___5 , not $11"> ___RAW_PRESERVED_16___11 . The story leaves no room for doubt.

When would the student's grouping be correct? Only if the brackets were actually printed:

10 ( 2 3 ) = 10 ( 1 ) = 11.

So 10 2 3 and 10 ( 2 3 ) are genuinely different expressions with different values, which shows that subtraction, like division, is not associative. The left-to-right convention is what settles the meaning of the unbracketed version.

The habit to build. Whenever you feel tempted to "do the easy pair first" in a run of additions and subtractions, resist. Move left to right, one operation at a time.

Exercise 12.

Is the statement a ÷ b × c = a ÷ ( b × c ) always true, sometimes true, or never true? Assume b and c are not zero, and justify your answer.

Answer

Sometimes true.

Solution

The answer is sometimes.

A case where it fails. Take a = 8 , b = 2 , c = 3 .

The left side, worked left to right:

8 ÷ 2 = 4 , 4 × 3 = 12.

The right side:

2 × 3 = 6 , 8 ÷ 6 = 4 3 .

Since 12 4 3 , the statement is false here. So it is certainly not always true.

A case where it holds. Take a = 8 , b = 2 , c = 1 .

The left side:

8 ÷ 2 = 4 , 4 × 1 = 4.

The right side:

2 × 1 = 2 , 8 ÷ 2 = 4.

Both give 4 , so the statement is true here.

Since it holds in one case and fails in another, it is sometimes true.

Which cases work. Writing both sides as fractions makes the pattern clear. The left side is

a b × c = a c b ,

and the right side is

a b c .

These agree exactly when a c b = a b c . Multiplying both sides by b c , which is allowed since b and c are non-zero, gives a c 2 = a . So either a = 0 , or c 2 = 1 , which means c = 1 or c = 1 .

That explains the successful example, where c was 1 , and it shows how special such cases are. For a randomly chosen c the statement will fail.

Why this matters. The left side is what a ÷ b × c actually means under the order of operations. The right side is what many people think it means. The gap between the two is the reason this section warns so strongly against writing expressions like a / b c at all: they invite exactly this confusion, and the safe course is to write a c b or a b c and leave nothing to interpretation.

Exercise 13.

Explain carefully why 3 2 = 9 rather than 9 , and state how you would write the expression if you wanted the answer 9 .

Solution

The rule involved. The minus sign in 3 2 is a unary minus: it sits in front of a single quantity and negates it, rather than sitting between two numbers as a subtraction. This section states that a unary minus has lower priority than exponentiation.

So exponentiation is carried out first, and the negation is applied to the result:

3 2 = ( 3 2 ) = ( 9 ) = 9.

Why the priority is set this way. The section explains the underlying reason when discussing why exponents outrank multiplication: an exponent belongs to the base immediately beneath it, and nothing more. In 3 2 the base written under the exponent is 3 , not 3 . For the base to be 3 , the minus sign would have to be attached to it by brackets.

There is also a strong practical reason. Algebraic expressions such as x 2 appear constantly, and they are always intended to mean ( x 2 ) . If the convention were the other way round, an expression like 5 x 2 would become ambiguous, since the reader could not tell whether the minus belonged to the subtraction or to the base.

How to get 9 . Use brackets to make the base explicit:

( 3 ) 2 = ( 3 ) × ( 3 ) = 9.

The brackets override the priority rules, which, as this section says, grouping symbols always do.

A summary of the two expressions.

3 2 = 9 (square the 3, then negate) ( 3 ) 2 = 9 (negate the 3, then square)

One further caution. The distinction disappears for odd exponents: both 3 3 and ( 3 ) 3 equal 27 , because an odd power keeps the sign of its base. So testing your understanding on a cube will not reveal whether you have the rule right. Always test with a square.

Exercise 14.

The expression 12 ÷ 3 ( 1 + 3 ) is ambiguous. Rewrite it in the two unambiguous ways described in this section, and give the value of each.

Answer

12 3 × ( 1 + 3 ) = 16   and   12 3 ( 1 + 3 ) = 1 .

Solution

The trouble lies in the notation 3 ( 1 + 3 ) , where the multiplication is shown by simply placing the 3 next to the bracket. This section calls that implied multiplication, or multiplication by juxtaposition, and explains that there is genuine disagreement about its priority.

Reading 1: juxtaposition is ordinary multiplication. Under this reading, 3 ( 1 + 3 ) means 3 × ( 1 + 3 ) , and the expression is treated by strict left-to-right PEMDAS. Brackets first:

1 + 3 = 4 ,

leaving 12 ÷ 3 × 4 . Division and multiplication share a level, so left to right:

12 ÷ 3 = 4 , 4 × 4 = 16.

Written so that no reader could mistake it, this is

12 3 × ( 1 + 3 ) = 16.

Reading 2: juxtaposition binds more tightly. Under this reading, the 3 and the bracket form a single visual unit that must be evaluated before the division. Brackets first again:

1 + 3 = 4 ,

then the juxtaposed product:

3 ( 4 ) = 12 ,

and finally the division:

12 ÷ 12 = 1.

Written unambiguously, this is

12 3 ( 1 + 3 ) = 1.

Which is right? Neither, and that is the point. As this section explains — using the closely related expression 8 ÷ 2 ( 2 + 2 ) that went viral in 2019 — both readings follow a consistent rule, but they follow different rules. Textbooks, calculators and software genuinely disagree: some scientific calculators give juxtaposition higher priority, while Google and Wolfram Alpha do not. The American Mathematical Society described the viral problem as ambiguous as written.

The real lesson. Do not try to memorise which convention "wins". Instead, never write an expression of this shape. Once the intent is expressed with a fraction bar or an extra pair of brackets, as in the two displayed forms above, there is nothing left to argue about. Clarity is the writer's job, not the reader's.

Exercise 15.

Evaluate

[ ( 2 3 2 ) × 3 3 2 ] 2 25 .
Answer

1

Solution

This combines several levels at once, so work patiently from the innermost grouping outward, writing one line per step.

Step 1: the innermost bracket, ( 2 3 2 ) . Inside it, the exponent comes before the subtraction:

2 3 = 8 , 8 2 = 6.

The expression becomes

[ 6 × 3 3 2 ] 2 25 .

Step 2: the numerator of the fraction. The fraction bar groups the top separately, so finish it off:

6 × 3 = 18.

Step 3: the denominator of the fraction. Likewise finish the bottom:

3 2 = 9.

The expression becomes

[ 18 9 ] 2 25 .

Step 4: the division. Only now that top and bottom are each a single number may we divide:

18 9 = 2.

The expression becomes

[ 2 ] 2 25 .

Step 5: the exponent and the root. Both sit at level 2:

2 2 = 4 , 25 = 5 because  5 2 = 25.

The expression becomes

4 5.

Step 6: the subtraction.

4 5 = 1.

Check the plausibility of the answer. The bracket collapsed to the small number 2 , so squaring it gives only 4 , while the square root contributes 5 . A negative final answer is therefore exactly what we should expect. If you obtained a large positive number, the likely cause is squaring before dividing, or taking 25 to be something other than 5 .

The technique to carry forward. Do not attempt several operations on one line. Each step above changed exactly one thing, which makes any error easy to locate. On a long expression this discipline is worth far more than speed.

Frequently Asked Questions

Does PEMDAS mean multiplication always comes before division?

No. "MD" in PEMDAS is a single level: multiplication and division have equal priority and are evaluated left to right. The letters M and D appear in that order only because "PEDMAS" is harder to pronounce. Whenever division appears to the left of multiplication, division is performed first.

Is PEMDAS the same as BODMAS?

Yes, they describe the same rules. PEMDAS is standard in the United States; BODMAS, BEDMAS, and BIDMAS are used in the UK, Canada, Australia, and other Commonwealth countries. The differences are purely in the English words chosen: parentheses vs. brackets, exponents vs. orders vs. indices. The mathematical priority hierarchy is identical everywhere. See the International Variants section for details.

What does the fraction bar do in the order of operations?

A fraction bar acts as an implicit parenthesis around both the numerator and the denominator. The entire numerator is evaluated first, the entire denominator is evaluated first, and then the division is performed. So 1 + 3 2 + 2 = 4 4 = 1 , not 1 + 3 ÷ 2 + 2 = 5 .

What is the correct answer to 8 ÷ 2 ( 2 + 2 ) ?

The expression is ambiguous. Applying strict left-to-right PEMDAS (treating 2 ( 2 + 2 ) as 2 × ( 2 + 2 ) ) gives 16 . Applying the convention that juxtaposition has higher priority than division gives 1 . Both are defensible under different conventions. In professional mathematical writing, such expressions are never used; the author would write either 8 2 ( 2 + 2 ) or 8 2 ( 2 + 2 ) to make the intent clear.

Is 3 2 equal to 9 or 9 ?

It equals 9 . By convention, exponentiation has higher priority than unary negation, so 3 2 is read as ( 3 2 ) = 9 . To get 9 , write ( 3 ) 2 explicitly.

Why do different calculators give different answers?

Calculators implement PEMDAS strictly left to right and do not give implied multiplication any special priority. In expressions like 1 / 2 n , most modern calculators compute ( 1 / 2 ) × n , while older models or some scientific calculators compute 1 / ( 2 × n ) . This is a calculator design choice, not a mathematical rule, which is why such notation should be avoided.