Published by Patrick Mutisya · 14 days ago
Know and understand the order in which mathematical operations are performed, including the use of brackets to make sure that formulae work correctly in a spreadsheet.
When a formula is entered into a cell, the spreadsheet program evaluates the expression automatically. If the intended sequence of calculations is not clear, the program will apply its default precedence rules, which may produce a result different from what the user expects. Using brackets (parentheses) allows the user to control the exact order in which parts of the formula are calculated.
The following table shows the hierarchy of operators that a spreadsheet follows when no brackets are used.
| Level | Operator(s) | Typical Example |
|---|---|---|
| 1 | Parentheses ( ) | \$ (2+3) \times 4 \$ |
| 2 | Exponentiation ^ | \$ 2 ^ 3 \$ |
| 3 | Multiplication * and Division / | \$ 6 \times 2 \div 3 \$ |
| 4 | Addition + and Subtraction ‑ | \$ 5 + 4 - 2 \$ |
Brackets can be nested to any depth. The innermost pair is evaluated first.
Example 1 – Without brackets:
=A1 + B1 * C1
If A1 = 2, B1 = 3, C1 = 4 then the spreadsheet calculates:
\$2 + 3 \times 4 = 2 + 12 = 14\$
Example 2 – With brackets to change the order:
=(A1 + B1) * C1
The same cell values give:
\$ (2 + 3) \times 4 = 5 \times 4 = 20 \$
Example 3 – Nested brackets:
=((A1 + B1) ^ 2) / (C1 - D1)
Assuming D1 = 1, the calculation proceeds as:
\$\frac{(2 + 3)^2}{4 - 1} = \frac{5^2}{3} = \frac{25}{3} \approx 8.33\$
#VALUE! or #REF! error.VALUE() or ensure the cell contains a numeric value.A1 = 5, B1 = 2, C1 = 3, what result does the formula =A1 - B1 ^ C1 produce?A1 and B1, multiplies the sum by the value in C1, then subtracts the value in D1. Show the formula and the order of evaluation.=(A1 - B1) ^ C1. This gives \$(5 - 2)^3 = 3^3 = 27\$.=(A1 + B1) * C1 - D1.Evaluation steps: