The order of operations is: parentheses first, then exponents, then multiplication and division from left to right, then addition and subtraction from left to right. PEMDAS and BODMAS are two acronyms for this same set of rules.
The four levels
Although PEMDAS has six letters, there are only four levels of priority. Multiplication and division share a level, and so do addition and subtraction.
| Priority | PEMDAS | BODMAS | Rule |
|---|---|---|---|
| 1 | Parentheses | Brackets | Work inside grouping symbols first, innermost first |
| 2 | Exponents | Orders | Powers and roots |
| 3 | Multiplication, Division | Division, Multiplication | Left to right, whichever comes first |
| 4 | Addition, Subtraction | Addition, Subtraction | Left to right, whichever comes first |
Notice that PEMDAS lists multiplication before division and BODMAS lists division before multiplication. Neither order matters, because the two operations have equal priority.
The left-to-right rule
This is the part most people forget. PEMDAS does not mean "do all multiplication, then all division". Within a level, you work from left to right.
- 12 ÷ 3 × 2 = 4 × 2 = 8. Doing the multiplication first would give 12 ÷ 6 = 2, which is wrong.
- 10 − 4 + 3 = 6 + 3 = 9. Doing the addition first would give 10 − 7 = 3, which is wrong.
Worked examples
Example 1. 5 + 2 × (8 − 3)² ÷ 10
- Parentheses: 8 − 3 = 5, giving 5 + 2 × 5² ÷ 10.
- Exponents: 5² = 25, giving 5 + 2 × 25 ÷ 10.
- Multiplication and division, left to right: 2 × 25 = 50, then 50 ÷ 10 = 5, giving 5 + 5.
- Addition: 10.
Example 2. 48 ÷ 6 × 2 − 3² + 4
- Exponents: 3² = 9, giving 48 ÷ 6 × 2 − 9 + 4.
- Multiplication and division, left to right: 48 ÷ 6 = 8, then 8 × 2 = 16, giving 16 − 9 + 4.
- Addition and subtraction, left to right: 16 − 9 = 7, then 7 + 4 = 11.
Example 3. 3 + 4 × 2 = 3 + 8 = 11, not 14. Multiplication outranks addition even though the addition is written first.
Classic viral traps
8 ÷ 2(2 + 2)
Following the standard rules strictly: the parentheses give 4, so the expression is 8 ÷ 2 × 4. Working left to right, 8 ÷ 2 = 4 and 4 × 4 = 16.
People who answer 1 are treating 2(2 + 2) as a single unit, so that the division applies to all of it. That reading, sometimes called implied multiplication priority, is used in some textbooks and by some calculators, which is why the problem spreads. The honest answer is that the expression is badly written. Under the standard school convention the answer is 16, and anyone who means the other thing should write 8 ÷ (2(2 + 2)).
6 ÷ 2(1 + 2)
The same issue. Standard rules give 6 ÷ 2 × 3 = 9. If you write math for others, use a fraction bar or extra parentheses so nobody has to guess.
−3² versus (−3)²
The exponent is applied before the negative sign, so −3² = −(3 × 3) = −9. To square negative three you need parentheses: (−3)² = 9. This catches people in spreadsheets and when substituting negative values into formulas.
Stacked exponents
Exponents are the one place where the direction reverses. A tower such as 2 to the power 3 to the power 2 is evaluated from the top down: 3² = 9 first, then 2⁹ = 512. Working the other way would give 8² = 64.
Hidden grouping symbols
Some notation groups things without visible parentheses.
- Fraction bars. In (6 + 4) over (3 + 2), the whole top and the whole bottom are evaluated first: 10 ÷ 5 = 2. Typed on one line it must be (6 + 4) ÷ (3 + 2). Without the parentheses, 6 + 4 ÷ 3 + 2 is about 9.33.
- Square root signs. √(9 + 16) = √25 = 5, which is not √9 + √16 = 7.
Common mistakes
- Always multiplying before dividing. They are equal priority. Go left to right.
- Trusting a basic calculator. Simple four-function calculators often compute each step as it is entered, so 3 + 4 × 2 shows 14. Scientific calculators and spreadsheets follow the proper order.
- Dropping parentheses when typing fractions. Type 1 ÷ (2 × 3), not 1 ÷ 2 × 3, which equals 1.5.
- Distributing an exponent over addition. (2 + 3)² is 25, not 2² + 3² = 13.
When an expression mixes fractions, the fraction calculator keeps numerators and denominators grouped correctly, and the scientific notation calculator does the same for powers of ten.
Run the numbers yourself
Common questions
What does PEMDAS stand for?
Parentheses, Exponents, Multiplication and Division, Addition and Subtraction. Multiplication and division share one level, and addition and subtraction share another, each worked left to right.
Is BODMAS different from PEMDAS?
No. BODMAS (Brackets, Orders, Division, Multiplication, Addition, Subtraction) describes the same rules with different words. Both give the same answers.
What is 8 ÷ 2(2 + 2)?
Under the standard left-to-right rule it is 16. Some people get 1 by giving implied multiplication higher priority, so the expression is ambiguous and should be written with extra parentheses.