Relvora Prep

GMAT Quant lesson · Counting

GMAT counting: slots, combinations, permutations and restrictions

How to count on GMAT Quant: the slot method, committees with combinations, arrangements with restrictions, repeated items, and at least one via the complement.

The core idea

Count by breaking a choice into steps and multiplying the number of options at each step. Decide whether order matters (permutations) or not (combinations), handle restrictions first, and count 'at least one' as everything minus none.

Core ideas

Words used here

  • Distinct: all different from each other. Identical: exactly alike, so swapping two of them changes nothing.
  • Factorial, written n!: n × (n − 1) × … × 2 × 1. For example, 4! = 4 × 3 × 2 × 1 = 24. By definition, 0! = 1.
  • Slot: one position to fill, such as the first digit of a code.
  • Permutation: a choice where order matters, such as 1st, 2nd and 3rd place. P(n, k) is the number of ways to fill k ordered positions from n distinct items.
  • Combination: a choice where order doesn't matter, such as a team. C(n, k), read "n choose k", is the number of ways to choose k items from n.
  • Restriction: a rule, such as "these two must sit together".
  • Complement: all the cases you don't want. "At least one" is everything minus its complement, "none".
  • Multiplication principle: if one step has m options and the next step has n options, the two steps together have m × n options. For 3 shirts and 4 pairs of pants: 3 × 4 = 12 outfits.
  • Arranging everything: n distinct items can be put in a row in n! ways. 4 books: 4! = 24 orders.
  • Ordered choice: P(n, k) = n × (n − 1) × … with k numbers multiplied. P(5, 3) = 5 × 4 × 3 = 60.
  • Unordered choice: C(n, k) = P(n, k) ÷ k!, because each group of k can be ordered k! ways. C(5, 3) = 60 ÷ (3 × 2 × 1) = 60 ÷ 6 = 10.
  • Repeated items: divide n! by the factorial of each repeat count.
  • At least one = total − none.

Try it. A club has 7 members. (a) In how many ways can it choose a president and a secretary? (b) In how many ways can it choose 2 members to send to a meeting?

Show the answer
  1. (a) The roles are different, so order matters: 7 choices for president, then 6 for secretary. 7 × 6 = 42.
  2. (b) The 2 members have the same job, so order doesn't matter. Each pair was counted twice in (a) (Ana then Ben, and Ben then Ana), so 42 ÷ 2 = 21. This is C(7, 2) = (7 × 6) ÷ (2 × 1) = 21.

The slot method

Draw one slot for each position. Write the number of options in each slot, then multiply (the multiplication principle). Fill the most restricted slot first, because it limits the others.

Why it works. Picture a tree. Each option in the first slot starts its own branch, and every branch splits into the same number of options at the next slot. The number of complete paths (the leaves of the tree) is the product of the options.

How to spot it: codes, license plates, digits, seats with roles: anything where the positions are different from each other.

Example. How many 4-digit codes can be made from the digits 1 through 9, with no digit repeated, if the code must end in an even digit?

  1. Last slot first (it has the restriction): 4 options (2, 4, 6 or 8).
  2. One digit is used, so the first slot has 9 − 1 = 8 options, the second 7, the third 6.
  3. Total: 4 × 8 × 7 × 6 = 32 × 42 = 1,344.
last digit: 4first: 84 × 8 = 32second: 732 × 7 = 224third: 6224 × 6 = 1,344
Fill the restricted slot first (4 even digits). Then 8, 7 and 6 digits are left for the other three slots.

Divisors as slots. 2³ × 3² × 5 means 2 × 2 × 2 × 3 × 3 × 5 = 360. Every divisor of 360 has the form 2^a × 3^b × 5^c. A divisor that is a multiple of 6 needs at least one 2 and at least one 3:

  • a can be 1, 2 or 3: 3 options.
  • b can be 1 or 2: 2 options.
  • c can be 0 or 1: 2 options (5⁰ = 1 means "no 5").
  • Total: 3 × 2 × 2 = 12 divisors.

Trap: filling the slots left to right (9 × 8 × 7 × …). Then you don't know how many even digits are still free for the last slot.

Three slots for gold, silver and bronze medals among 5 runners: 5 choices for gold, then 4 for silver, then 3 for bronze, so 5 × 4 × 3 = 60 ways.

Edge cases.

  • Repeats allowed: every slot keeps its full count, as in 10 × 10 × 10 = 1,000 three-digit codes.
  • A number can't start with 0. A 3-digit number has 9 options for its first digit, not 10.
  • Two restricted slots that use the same digits: fill the strictest one first, then the other, then the rest.

GMAT-level example. How many odd 3-digit numbers have no repeated digit?

  1. Last digit (the restriction "odd"): 1, 3, 5, 7 or 9, so 5 options.
  2. First digit: not 0 and not the digit already used, so 10 − 2 = 8 options.
  3. Middle digit: any digit except the two already used, so 10 − 2 = 8 options.
  4. Total: 5 × 8 × 8 = 320.

Filling left to right fails here: after choosing the first digit, you don't know whether it used up one of the odd digits.

Check yourself. In how many ways can gold, silver and bronze medals go to 8 runners?

Check your answer

8 × 7 × 6 = 336.

Choosing a committee

A committee has no order: {Ana, Ben} is the same committee as {Ben, Ana}. So use combinations. C(n, k) is the number of ways to choose k people from n when order doesn't matter: multiply k numbers counting down from n, then divide by k!. If the committee needs a set number from each group, choose from each group separately and multiply.

Why it works. Counting ordered picks counts each group once for every order of its members. A group of k people can be ordered in k! ways, so dividing the ordered count by k! leaves each group counted once.

How to spot it: "committee", "team", "select", "group of", with no roles given.

Example. A panel must have 2 managers chosen from 5 and 3 analysts chosen from 7. How many panels are possible?

  1. Managers: C(5, 2) = (5 × 4) ÷ (2 × 1) = 20 ÷ 2 = 10.
  2. Analysts: C(7, 3) = (7 × 6 × 5) ÷ (3 × 2 × 1) = 210 ÷ 6 = 35.
  3. Each manager pair can go with each analyst group: 10 × 35 = 350.

Games and handshakes are committees of two. If each of 8 players plays every other player once, there are C(8, 2) = (8 × 7) ÷ 2 = 28 games.

Trap: C(12, 5) = 792 chooses any 5 of the 12 people, so it includes panels with the wrong mix of managers and analysts.

Try it. A team needs 2 boys from 4 and 2 girls from 6. How many teams are possible?

Show the answer
  1. Boys: C(4, 2) = (4 × 3) ÷ 2 = 6.
  2. Girls: C(6, 2) = (6 × 5) ÷ 2 = 15.
  3. Teams: 6 × 15 = 90.

A 4 by 4 grid of ordered pairs from A, B, C and D, with the diagonal empty. There are 12 ordered pairs. Each pair above the diagonal (AB, AC, AD, BC, BD, CD) matches one below it (BA, CA, DA, CB, DB, DC), so there are 12 ÷ 2 = 6 unordered pairs: C(4, 2) = 6.

Edge cases.

  • C(n, k) = C(n, n − k). Choosing 3 of 5 to go is the same as choosing the 2 who stay: C(5, 3) = C(5, 2) = 10.
  • A role inside the group ("a chair and 3 other members") is chosen separately: n × C(n − 1, 3).
  • "At least" and "at most" need cases or the complement.

GMAT-level example. A committee of 4 is chosen from 6 women and 5 men. It must include at least 2 women. How many committees are possible?

  1. All committees: C(11, 4) = (11 × 10 × 9 × 8) ÷ 24 = 330.
  2. Not allowed: 0 women, C(5, 4) = 5; and 1 woman, 6 × C(5, 3) = 6 × 10 = 60.
  3. Allowed: 330 − 5 − 60 = 265.
  4. Check by cases: 2 women C(6, 2) × C(5, 2) = 15 × 10 = 150; 3 women 20 × 5 = 100; 4 women 15. And 150 + 100 + 15 = 265 ✓.
330 committees0 or 1 woman: 650 women: 51 woman: 602+ women: 2652 women: 1503 women: 1004 women: 15
Split all C(11, 4) = 330 committees by the number of women: 330 − 5 − 60 = 265 = 150 + 100 + 15.

Check yourself. 10 people each shake hands once with every other person. How many handshakes are there?

Check your answer

C(10, 2) = (10 × 9) ÷ 2 = 45.

Arrangements with a restriction

For "must be together", glue the group into one block. Arrange the block and the other items, then multiply by the number of orders inside the block. For "must not be together", count all arrangements and subtract the ones where they are together. Here n! (n factorial) = n × (n − 1) × … × 1 is the number of ways to put n distinct items in a row.

Why it works. Gluing turns "these two are together" into "this one unit is somewhere in the row", which is a plain arrangement. Subtracting works because every arrangement either has the two books together or doesn't, never both.

How to spot it: "next to each other", "not next to each other", "must sit at the end".

Example. In how many ways can 6 books be placed on a shelf if two particular books must not be next to each other?

  1. All arrangements: 6! = 6 × 5 × 4 × 3 × 2 × 1 = 720.
  2. Together: glue the two books into one block. Now there are 5 units (the block + 4 books): 5! = 120 orders. Inside the block the two books can be in 2 orders: 120 × 2 = 240.
  3. Not together: 720 − 240 = 480.
all orders: 6!720together or aparttogether: 240apart: 480
Each of the 720 orders has the two books together (5! × 2 = 240) or apart, so apart is 720 − 240 = 480.

Trap: forgetting the 2 orders inside the block. Then you get 720 − 120 = 600.

Edge cases.

  • Fixed positions first. "A must be at one end": 2 choices for A's end, then 5! for the rest.
  • "A before B" (not necessarily next to each other): in exactly half of all orders A comes first, so 720 ÷ 2 = 360.
  • A block of three has 3! = 6 orders inside it.

GMAT-level example. In how many ways can 3 boys and 3 girls stand in a row if boys and girls must alternate?

  1. The pattern is either B G B G B G or G B G B G B: 2 patterns.
  2. In each pattern, the 3 boys fill their 3 places in 3! = 6 ways, and the 3 girls fill theirs in 6 ways.
  3. Total: 2 × 6 × 6 = 72.

Check yourself. In how many orders can 6 books be placed if book A must be somewhere to the left of book B?

Check your answer

Half of 6! = 720: 360.

Arrangements with identical items

When some items are identical, swapping them doesn't create a new arrangement. So divide the total number of arrangements, n! (n factorial), by the factorial of each repeat count.

Why it works. Give the identical items labels for a moment: L₁ and L₂. Now all 5 letters are different and there are 5! orders. Each real arrangement appears 2! times, once for each order of L₁ and L₂ (and again for the Es). Dividing by each repeat count's factorial removes those copies.

How to spot it: letters of a word with repeated letters, identical flags or balls, "indistinguishable" (can't be told apart).

Example. How many different arrangements are there of the letters in LEVEL?

  1. 5 letters: L twice, E twice, V once.
  2. If all 5 letters were different: 5! = 120.
  3. Swapping the two Ls changes nothing (divide by 2! = 2), and swapping the two Es changes nothing (divide by 2! = 2 again).
  4. 120 ÷ (2 × 2) = 120 ÷ 4 = 30.
5! = 120two Ls: ÷ 2!120 ÷ 2 = 60two Es: ÷ 2!60 ÷ 2 = 30
Count as if all 5 letters were different, then divide out the 2! orders of the Ls and the 2! orders of the Es.

Sharing identical items. To give 10 identical cards to 3 people, with each person getting at least one, line the cards up. There are 9 gaps between them. Put 2 dividers in 2 different gaps to cut the line into 3 non-empty piles. That is C(9, 2) = (9 × 8) ÷ 2 = 36 ways.

Trap: answering 5! = 120. That counts each arrangement 4 times.

Edge cases.

  • Two kinds of item = choosing positions. 3 heads and 2 tails can be arranged in 5! ÷ (3! × 2!) = 10 ways, which is C(5, 2): choose where the tails go.
  • Grid paths: a shortest path 3 steps right and 2 steps up is an arrangement of R, R, R, U, U: also 10.
  • Restrictions combine with repeats: glue or subtract as before, then divide.

GMAT-level example. In how many arrangements of the letters of BANANA are the two Ns not next to each other?

  1. All arrangements: 6 letters with A three times and N twice: 6! ÷ (3! × 2!) = 720 ÷ 12 = 60.
  2. Ns together: glue NN into one block. Now there are 5 units (B, A, A, A, NN), with A three times: 5! ÷ 3! = 20. (The two Ns are identical, so the block has only 1 order inside.)
  3. Not together: 60 − 20 = 40.

Check yourself. In how many ways can 3 identical red flags and 2 identical blue flags be hung in a row?

Check your answer

5! ÷ (3! × 2!) = 120 ÷ 12 = 10.

Circular arrangements

Around a round table, if everyone moves one seat to the right, the seating looks the same: each person has the same neighbors. So fix one person's seat and arrange the others in a row: (n − 1)! ways for n distinct people, where n! = n × (n − 1) × … × 1. Restrictions work as in a row: glue a block, or subtract.

Why it works. Every seating of n people has n rotations, and all n of them look the same at a round table. So the n! row orders come in groups of n identical seatings: n! ÷ n = (n − 1)!.

How to spot it: "around a circular table", "in a ring", where only who sits next to whom matters.

Example. In how many ways can 6 people sit around a round table if two of them must sit together?

  1. Glue the pair into one unit: now there are 5 units around the table.
  2. Around the table: (5 − 1)! = 4! = 4 × 3 × 2 × 1 = 24.
  3. The pair can sit in 2 orders: 24 × 2 = 48.

Trap: using 5! = 120 for the units. That counts every rotation as a new seating.

Four small round tables. Each seats A, B, C and D in the same clockwise order, rotated one seat further each time. All four are the same seating, because everyone has the same neighbors. So 4 people have 4! ÷ 4 = 3! = 6 different seatings.

Edge cases.

  • Numbered seats make rotations different, so use n!.
  • "Must not sit together" around a table: count all seatings and subtract those with the pair together.
  • A ring that can be flipped over (a key ring) also counts mirror images as the same: (n − 1)! ÷ 2. GMAT questions rarely use this.

GMAT-level example. In how many ways can 6 people sit around a round table if two of them must not sit next to each other?

  1. All seatings: (6 − 1)! = 5! = 120.
  2. Seatings with the two together: 48 (worked out in the example above).
  3. Not together: 120 − 48 = 72.

Check yourself. In how many ways can 5 people sit around a round table?

Check your answer

(5 − 1)! = 4! = 24.

At least one, via the complement

The complement of "at least one" is "none". Count every possible selection, then subtract the selections with none of the required type. This is faster than adding exactly-one, exactly-two, and so on. Here C(n, k) is the number of ways to choose k items from n when order doesn't matter.

Why it works. Every team either has no juniors or has at least one, never both. So the two counts add up to all teams, and "at least one" = all − none.

How to spot it: "at least one", "one or more", "not all from the same group".

Example. A 4-person team is chosen from 6 seniors and 5 juniors. How many teams include at least one junior?

  1. All teams from 11 people: C(11, 4) = (11 × 10 × 9 × 8) ÷ (4 × 3 × 2 × 1) = 7,920 ÷ 24 = 330.
  2. Teams with no juniors (all 4 from the 6 seniors): C(6, 4) = (6 × 5 × 4 × 3) ÷ 24 = 360 ÷ 24 = 15.
  3. At least one junior: 330 − 15 = 315.

Trap: picking "one junior, then any 3 others" gives 5 × C(10, 3) = 5 × 120 = 600. This counts a team with two juniors twice: once for each junior picked "first".

Try it. A 3-person group is chosen from 5 men and 4 women. How many groups include at least one woman?

Show the answer
  1. All groups: C(9, 3) = (9 × 8 × 7) ÷ (3 × 2 × 1) = 504 ÷ 6 = 84.
  2. No women (all 3 from the 5 men): C(5, 3) = (5 × 4 × 3) ÷ 6 = 60 ÷ 6 = 10.
  3. At least one woman: 84 − 10 = 74.

Edge cases.

  • "At most" works the same way: total − (more than the limit).
  • The complement of "at least two" is "zero or exactly one", two cases to subtract.
  • "Not all from the same group" = total − (all from group 1) − (all from group 2).

GMAT-level example. How many 4-digit PIN codes (digits 0 to 9, repeats allowed, 0 allowed first) contain at least one 7?

  1. All codes: 10 × 10 × 10 × 10 = 10,000.
  2. Codes with no 7: 9 options per digit, so 9⁴ = 6,561.
  3. At least one 7: 10,000 − 6,561 = 3,439.
all codes: 10⁴10,000with or without a 7no 7: 6,561a 7: 3,439
Codes with no 7 (9⁴ = 6,561) and codes with at least one 7 make up all 10,000, so 3,439 have a 7.

Check yourself. A committee of 3 is chosen from 4 men and 4 women. How many committees include at least one man and at least one woman?

Check your answer

All: C(8, 3) = 56. All men: C(4, 3) = 4. All women: 4. Mixed: 56 − 4 − 4 = 48.

How hard questions disguise it

For harder questions (L4–L5)

L4 questions stack two restrictions ("must include at least one junior and must not include Dana") or mix ordered and unordered steps (choose a committee, then pick its chair). L5 versions feed counting into probability, where the count becomes a numerator over a total, or into divisibility ("how many 3-digit numbers with distinct digits are divisible by 5?"). Write out the steps in words, decide at each step whether order matters, and handle the restricted step first.

Practice

Sharpen these counting patterns in timed sets on the counting practice page.

Common traps

  • Adding when the choices combine, or dropping a step

    When you make one choice AND another, multiply the counts, one factor per step. Adding them, or leaving out a step such as the jacket or the third office, undercounts badly.

  • Getting order wrong, including in pairs

    Use permutations only for lineups, rankings or distinct roles, and combinations for groups. A game or handshake is an unordered pair: n people make C(n, 2) = n(n − 1)/2 of them.

  • Ignoring the condition in the question

    The restriction is the point of the question: one of each kind, no repeated person, a fixed split. Count only arrangements that meet it, or count all of them and subtract the ones that break it.

  • Subtracting the wrong cases, or answering them

    When you count by subtraction, the answer is total minus the cases that break the condition. Identify exactly which cases are forbidden (both together, not neither), and don't report them as the answer.

  • Fixing one member, then filling freely

    Choosing 'one woman, then anyone' counts a committee with two women twice. Use total minus none, or add the exact cases (exactly one, exactly two…).

  • Mishandling the block or the gaps

    When people must sit together, treat them as one unit among the others, then multiply by the ways they can be ordered inside the block. In the gap method, the separated items can fill their gaps in either order too.

  • Counting rotations as new seatings

    Around a round table, only relative positions matter, so n units can be seated in (n − 1)! ways, not n!. Fix one unit's seat and arrange the rest.

  • Treating identical items as distinct

    Swapping two identical flags makes no new signal, so divide n! by the factorial of every repeat count. Divide, don't multiply, and do it for each color.

  • Splitting identical items among people wrong

    To give n identical items to k people, each getting at least one, place k − 1 dividers in the n − 1 gaps between items: C(n − 1, k − 1) ways.

  • Counting divisors with a condition wrong

    Count divisors as slots of exponents. A multiple of 6 needs at least one 2 and one 3, while a prime the condition doesn't mention can still have exponent 0.

  • Missing a remainder pattern in a divisible sum

    Sort the numbers by their remainder when divided by 3. Three of them have a sum divisible by 3 when all three share a remainder or when there is one from each group, so count every pattern; the groups are usually not one third each.