Sub topic 16
Common Mistakes and Why PEMDAS Can Mislead
Assume you can add, subtract, multiply, and divide integers and fractions, and that an exponent shows repeated multiplication. This chapter focuses on errors that happen after you already know the basic order of operations.
PEMDAS is a memory aid:
- Parentheses
- Exponents
- Multiplication and division
- Addition and subtraction
The letters do not mean that multiplication always comes before division, or that addition always comes before subtraction. Operations on the same level are evaluated from left to right.
| Expression | Correct grouping | Value |
|---|---|---|
| `24 / 4 * 3` | `(24 / 4) * 3` | 18 |
| `10 - 4 + 3` | `(10 - 4) + 3` | 9 |
| `2 + 3 * 4` | `2 + (3 * 4)` | 14 |
Mistake: applying multiplication before division
In 24 / 4 * 3, division and multiplication have equal precedence. Work from the left:
24 / 4 * 3
= 6 * 3
= 18If you multiply first, you get 24 / 12 = 2, which changes the expression's grouping.
Subtraction and addition work the same way:
10 - 4 + 3
= 6 + 3
= 9Mistake: confusing a negative sign with a negative base
An exponent normally applies to the number immediately beside it, before a leading negative sign:
-3^2 = -(3^2) = -9Parentheses make the negative number the base:
(-3)^2 = (-3)(-3) = 9This distinction matters whenever an expression contains an even or odd exponent. Always add parentheses when you mean a negative base.
Mistake: ignoring the grouping in a fraction
A fraction bar groups its entire numerator and denominator. For example,
(3 + 5) / (2 + 2) = 8 / 4 = 2It does not mean that only 5 is divided by 2. When entering the expression in a calculator or program, type parentheses around both parts.
Similarly,
(2 / 3)^2 = 4 / 9means that both the numerator and denominator are raised to the power.
Mistake: trusting ambiguous notation
Expressions such as 8 ÷ 2(2 + 2) are ambiguous because different conventions may group the multiplication differently. Write the intended grouping explicitly:
(8 / 2)(2 + 2) = 16
8 / (2(2 + 2)) = 1Clear parentheses are better than relying on a mnemonic.
Checking a result with Python
Code can expose a misplaced parenthesis or an incorrect assumption. Python follows its own documented precedence rules:
print(-3 ** 2) # -9
print((-3) ** 2) # 9
print(24 / 4 * 3) # 18.0
print(10 - 4 + 3) # 9Use code to check a calculation, not to replace the written grouping that explains why the result is correct.
Exercise
Evaluate -2^3 + 12 / 3 * 2. Then evaluate (-2)^3 + 12 / 3 * 2.
Show answer
The first expression is -(2^3) + (12 / 3) * 2 = -8 + 8 = 0. The second is (-2)^3 + (12 / 3) * 2 = -8 + 8 = 0. In this example the results match, but the grouping of the negative base is still different.