PEMDAS: Remembering Math's Order of Operations

By: Mark Mancini & Desiree Bowie  | 
PEMDAS is the tried-and-true method that gives us the order to work when solving mathematical problems. HowStuffWorks

Nearly every middle school in the U.S. teaches its students to remember this simple phrase: "Please excuse my dear Aunt Sally." But why are we apologizing for her behavior? Did she wear white after Labor Day or something?

The world may never know. In all seriousness, "Please Excuse My Dear Aunt Sally," or PEMDAS, is just a mnemonic. It's a tool educators use to help us memorize information through a catchy rhyme, phrase or acronym. Now let's explore how to use this tool to solve equations.



PEMDAS is an acronym and mnemonic that represents a set of rules used to clarify the order in which operations should be performed to correctly evaluate mathematical expressions. PEMDAS stands for:

  1. Parentheses: This means any calculations inside parentheses should be performed first. This can include brackets or other grouping symbols.
  2. Exponents: This refers to powers or square roots. You handle these calculations after dealing with parentheses but before other operations.
  3. Multiplication: When you encounter multiplication in an expression, after parentheses and exponents, you perform this operation next.
  4. Division: Similar to multiplication, you handle division after parentheses and exponents, working from left to right.
  5. Addition: After the aforementioned operations, you perform addition.
  6. Subtraction: Lastly, after all the other operations have been handled, you perform subtraction.

Sometimes, the mnemonic "BEDMAS" is used, where "B" stands for "brackets," and serves the same purpose as "parentheses." The mnemonics essentially convey the same order of operations to reach the correct answer, but they use slightly different terminology based on regional preferences. For example, BEDMAS is more commonly used in Canada, while PEMDAS is prevalent in the U.S.


(Note that multiplication and division are of equal precedence in the order of operations, so the flipped order in BEDMAS doesn't change anything.)


Origins of the Order of Operations

The order of operations — as Americans know it today — was probably formalized in either the late 18th century. By the 20th century, the tool gained wider acceptance, coinciding with the rise of the U.S. textbook industry.

In an email, math and science historian Judith Grabiner explains that concepts like the order of operations are best thought of as "conventions, like red-means-stop and green-means-go, not mathematical truths.


"But once the convention is established," she says, "the analogy to traffic lights holds: Everybody's got to do it the same way and the 'same way' has to be 100 percent unambiguous."

Math and ambiguity are uncomfortable bedfellows.


Why Do We Use PEMDAS?

PEMDAS ensures consistency in the results of mathematical calculations. Basically, when different people evaluate the same expression, they use the same process and come to the same result. If you don't follow the correct order of operations, you will likely get the wrong answer.

Ignoring or changing this order can lead to different results, which can be especially problematic in fields like science, engineering and finance where precise calculations are crucial.


Solving Math Equations Using the PEMDAS Rule

Suppose it's finals week, and you're expected to solve the following equation:

9 – (2 x 3) x 4 + 5² = ?

Don't panic. This is where a certain auntie comes in. For every word in the phrase, "Please excuse my dear Aunt Sally," there's a corresponding math term (which begins with the same letter) that tells us which procedure(s) to perform first.


Parentheses First

Before we solve the equation, PEMDAS dictates that we ask ourselves a simple question: "Are there any parentheses?" If the answer is "yes," then our first move should be to resolve whatever's inside them.

So in the above example, we see "2 x 3" enclosed in the parentheses. Therefore, we'll begin by multiplying 2 times 3, which gives us 6. Now the equation looks like this:

9 – 6 x 4 + 5² = ?

Cool beans. Time to bring on the exponents! In print, exponents take the form of a little number pressed against the upper righthand corner of a larger number. See the ? That itty-bitty "2" is an exponent.

Here, the tiny two tells us to multiply 5 by itself. And 5 x 5 equals 25, giving us this:

9 – 6 x 4 + 25 = ?

Now that we've taken care of the parentheses and exponent(s), let's proceed to those next two operations: multiplication and division.

Multiply and Divide

Note that we're not saying multiplication comes before division here. Not necessarily, at least.

Let's say you're looking at a different problem which — at this stage — contains both a multiplication sign and a division symbol. Your job would be to perform the two operations in order from left to right.

The concept is best explained by way of example. If the equation reads 8 ÷ 4 x 3, first you'd divide the 8 by the 4, giving you 2. Then — and only then — would you multiply that 2 by 3. We now return to our regularly scheduled math problem:

9 – 6 x 4 + 25 = ?

Whoever wrote the original equation kept things nice and simple; there's nary a division sign in sight and only one multiplication symbol. Thank you, merciful exam gods.

Without further ado, we're going to multiply the 6 by the 4, giving us 24.

9 – 24 + 25 = ?

Time to Add and Subtract

As with multiplication and division, addition and subtraction are part of the same step. Once again, we're performing these two operations in order, from left to right. So we're going to have to subtract that 24 from the 9.

Doing so will give us a negative number, specifically -15.

But the 25 is a positive number. So in its current form, the equation consists of a negative 15 plus a positive 25. And when you add those two together, you get a positive 10.

So there it is. The answer to our riddle.

9 – (2 x 3) x 4 + 5² = 10

Double Parentheses: Proceed With Care

Before we part ways, there are a few more things you should know. You may someday find yourself looking at a complex equation with lots of different operations sandwiched between two parentheses. Maybe something like this:

9 – ((2³ – 3) x 8) ÷ 6 = ?

Don't sweat it. If you're trying to solve math problems with multiple operations, following the PEMDAS sequence ensures consistent and accurate results. All you've got to do is work through the PEMDAS process inside those parentheses before you move on to the rest of the problem.

Here, you'd take care of the exponent first (i.e., the 2³), then handle the subtraction in that set of parenthesis before moving on to the multiplication in the next level of parenthesis. Easy-peasy. (In case you're interested, the answer to the equation is 2 1/3, or 2.33 if you prefer decimals.)



Here are some other PEMDAS-eque conventions and methods related to arithmetic expressions:

  1. BODMAS/BIDMAS: Used in the U.K. and other regions, BODMAS stands for Brackets, Orders (or Indices for BIDMAS), Division, Multiplication, Addition and Subtraction.
  2. FOIL: Specifically for binomials, it stands for First, Outer, Inner, Last. It's a method for multiplying two binomials.
  3. Factorization: Breaking down numbers or expressions into their simplest components.
  4. Distributive property: For expressions like a(b + c), it would be ab + ac.
  5. Associative and commutative properties: Respectively, these properties allow numbers to be grouped differently or moved around in an expression without changing the result.
  6. Completing the square: A technique used in quadratic equations to convert them into a perfect square trinomial.
  7. Rationalizing the denominator: A method used to eliminate radicals from a denominator of a fraction.

This article was updated in conjunction with AI technology, then fact-checked and edited by a HowStuffWorks editor.



Is PEMDAS wrong?
In the U.S., PEMDAS is more common where we first calculate Parentheses, then Exponents, then Multiplication and Division, and Addition and Subtraction at the end. However, most of the world uses BODMAS — Brackets, Orders, Division, Multiplication, Addition and Subtraction.
Why is PEMDAS in that order?
PEMDAS basically creates a pyramid for different functions in an equation. For example, the first priority is given to the parentheses — and for good reason. Not only does this give order to equations but also drives more accurate results.
What is the formula of PEMDAS?
According to PEMDAS, it is important that the equation is simplified before it is calculated. This means squaring any roots off on both sides, any canceling effects and more. After that, the parentheses, exponents, multiplication, division, addition and subtraction order must be followed, solving each element from left to right.
What is better BODMAS or PEMDAS?
There has been a long debate about whether BODMAS or PEMDAS is better but the difference between them primarily arises from regional terminology and preferences. Some say there is no difference between the two since they suggest that multiplication and division must be done from left to right, regardless of what comes first, while others prefer to follow the BODMAS mnemonic.