Skip to content

9709 · Unit 25 · Paper 5: Probability and Statistics 1

Permutations and combinations.

9709 · Unit 25 · Permutations and combinations
Revisionbyexamplicity

Arranging in a line: factorials and repeats

§5.2 · Permutations and combinations

Lining up seven different things is a chain of choices: 7 for the first place, 6 for the next, down to 1. That product is the factorial 7!. Repeated letters, as in a, a, b, b, c, c, c, cut the count down.

ABCDEFGA–D: four blue · E–G: three goldSeven different physical objectsABCDEFGA–D: four blue · E–G: three goldSeven different physical objects

1Fill seven places: multiply the choices

Count the choices for each place in turn, then multiply. n different objects in a line: n! orders.
F1A2D3G4B5C6E77654321Choices left when filling positions 1 to 7One complete arrangement: F A D G B C EF1A2D3G4B5C6E77654321Choices left when filling positions 1 to 7One complete arrangement: F A D G B C E
Worked example

In how many orders can the seven tokens A–G stand in a line?

  1. Place 1 has 7 choices, place 2 has 6, and so on
    N=7×6×5×4×3×2×1
  2. Write the product as a factorial
    N=7!
  3. Answer
    5040 orders
✓Check A and B are both blue, but they are still different tokens
0! = 1. When nothing is left to place, there is one way to finish: place nothing. It keeps n! = n × (n − 1)! true at n = 1.

2Repeated letters: divide out the copies

Count as if every copy were different, then divide by the orders of each repeated letter: n!p!q! for letters repeated p and q times.
aabbcccIdentical copies have no subscripts.a₁ a₂ b₁ b₂ c₁ c₂ c₃a₂ a₁ b₂ b₁ c₃ c₁ c₂Erasing labels gives a a b b c c c both times.
Worked example

How many different strings can be made from a, a, b, b, c, c, c?

  1. Pretend every copy is different
    7!=5040
  2. Each string appears once for every order of its copies
    2! × 2! × 3!=24
  3. Divide
    N=7!2!×2!×3!
  4. Answer
    210 strings
Divide only for letters that repeat: a letter used once has 1! = 1. Never divide for the tokens A–G: swapping A and B changes what you see.

3Try it

Your turn

1 In how many orders can five different books stand on a shelf?

2 How many different strings can be made from p, p, q, q, q?

3 How many different strings can be made from x, x, y, y, y, z, z, z?

  1. 1
    5! = 120
  2. 2
    5!/(2! 3!) = 10
  3. 3
    8!/(2! 3! 3!) = 40320/72 = 560
Tick what you can do now
Practise with s26/52 Q1(b) (related distinct-object counting); m26/52 Q2(a); s26/51 Q5(b); s26/53 Q6(a)
1 / 6
9709 · Unit 25 · Permutations and combinations
Revisionbyexamplicity

Order or no order: permutations and combinations

§5.2 · Permutations and combinations

Sometimes the places are labelled, like first, second and third prize. Sometimes only the group matters, like a team. A permutation counts ordered selections; a combination counts groups. Every group of three has 3! = 6 orders, and that links the two.

1Fill labelled places: a permutation

Fill r labelled places from n different objects: ⁿPᵣ=n!(n−r)!.
Position 1A7 choicesPosition 2C6 choicesPosition 3E5 choicesA C E and E C A are different outcomes.ECA
Worked example

Three of the tokens A–G fill positions 1, 2 and 3. How many ways?

  1. Count the choices place by place
    N=7×6×5
  2. The same as 7!/4!: the four unused tokens are not placed
    ⁷P₃=504024
  3. Answer
    210 ways
✓Check ACE and ECA are different outcomes

2A token that must be used: place it first

Worked example

Three of the tokens A–G fill positions 1, 2 and 3, and A must be one of them. How many ways?

  1. Choose the position for A
    3 ways
  2. Fill the other two positions from B–G
    6 × 5=30
  3. Answer
    3 × 30 = 90 ways
6 × 5 on its own fixes A in one position. Multiply by the 3 positions A could take.

3Choose a group: a combination

Keep only the group: divide the ordered count by r!. (nr)=n!r!(n−r)!, also written ⁿCᵣ.
ACEAECCAECEAEACECAAll six orders become the same group {A, C, E}.
Worked example

How many groups of three can be chosen from A–G?

  1. Count ordered triples
    7 × 6 × 5=210
  2. Each group appears in 3! = 6 orders
    (73)=2106
  3. Answer
    35 groups
✓Check choosing the four left behind gives ⁷C₄ = 35 too

4Order or group? Read what is recorded

What is recordedA, C, E against E, C, ACount from A–G
Positions 1, 2, 3different outcomes⁷P₃ = 210 permutations
A group of threethe same group⁷C₃ = 35 combinations
Do not divide by 3! while the places are still labelled.

5Try it

Your turn

1 A club of nine members chooses a captain, a vice-captain and a secretary. How many ways?

2 How many teams of four can be chosen from the nine members?

3 Four of the tokens A–G fill positions 1 to 4, and B must be one of them. How many ways?

  1. 1
    ⁹P₃ = 9 × 8 × 7 = 504
  2. 2
    ⁹C₄ = 126
  3. 3
    4 places for B, then 6 × 5 × 4: 4 × 120 = 480
Tick what you can do now
Practise with s26/52 Q3(a), Q3(b) (related ordered-position practice); m26/52 Q1; s26/52 Q1(a)
2 / 6
9709 · Unit 25 · Permutations and combinations
Revisionbyexamplicity

Together or apart: blocks and gaps

§5.2 · Permutations and combinations

Two conditions come up again and again: some objects must stand together, or some must stand apart. For together, glue them into one block. For apart, line up everything else first, then drop the separated objects into the gaps.

1Together: glue a block

Count the block as one object, then multiply by the orders inside the block.
EABDFGCone AB blockExternal objects: [AB], C, D, E, F, GInternal orders: AB or BA
Worked example

Arrange A–G in a line with A and B next to each other.

  1. AB is one object: six objects to arrange
    N=6!×2!
  2. Inside the block: AB or BA
    720 × 2
  3. Answer
    1440 arrangements

2A block of identical letters has one inside order

Worked example

Arrange a, a, b, b, c, c, c with the two a together and the two b apart.

  1. Glue aa and arrange [aa], b, b, c, c, c
    N=6!2!×3!=60
  2. Count the ones where bb is together too
    N=5!3!=20
  1. Subtract inside the aa-together count
    60 − 20
  2. Answer
    40 strings
✓Check aabcbcc is counted; aabbccc is not

3Apart: drop into gaps

n objects in a line leave n + 1 gaps, counting both ends. Put at most one separated object in each gap.
Distinct A, B, C01234DEFGChoose three of the five gaps.ADEBFGCGaps 0, 2 and 4 used here.Identical c symbols01234aabbChoose three of the five gaps.caacbbcGaps 0, 2 and 4 used here.Distinct A, B, C01234DEFGChoose three of the five gaps.ADEBFGCGaps 0, 2 and 4 used here.Identical c symbols01234aabbChoose three of the five gaps.caacbbcGaps 0, 2 and 4 used here.
Worked example

Arrange A–G so that no two of A, B, C are next to each other.

  1. Arrange D, E, F, G
    4!=24
  2. Choose three of the five gaps
    ⁵C₃=10
  3. Put A, B, C in those gaps in order
    3!=6
  4. Answer
    24 × 10 × 6 = 1440Multiply the three counts.
Worked example

Arrange a, a, b, b, c, c, c with no two c next to each other.

  1. Arrange a, a, b, b
    4!/(2! 2!)=6
  2. Choose three gaps for c
    ⁵C₃=10
  3. Answer
    6 × 10 = 60No 3!: the c are identical.
Arrange A–G so that no two of A, B, C are next to each other.
4! = 24Arrange D, E, F, G.⁵C₃ = 10Choose three of the five gaps.3! = 6Put A, B, C in those gaps in order.24 × 10 × 6 = 1440Multiply the three counts.
Arrange a, a, b, b, c, c, c with no two c next to each other.
4!/(2! 2!) = 6Arrange a, a, b, b.⁵C₃ = 10Choose three gaps for c.6 × 10 = 60No 3!: the c are identical.

4“Not all together” is a different question

For two objects, apart = all − together: 5040 − 1440 = 3600. For three, “not all three together” still allows a pair.
  1. Glue ccc; arrange [ccc], a, a, b, b
    all c together=5!2!×2! = 30
  2. Subtract from all 210 strings
    not all c together=210−30
  3. Answer
    180 stringsMore than the 60 with no two c together.
all c together=5!2!×2! = 30Glue ccc; arrange [ccc], a, a, b, b.not all c together=210−30Subtract from all 210 strings.180 stringsMore than the 60 with no two c together.
ccababc has a pair cc but not ccc: it is one of the 180, not one of the 60.

5Try it

Your turn

1 Six different books stand on a shelf, with two particular books next to each other. How many orders?

2 Arrange the letters p, q, r, s, t so that p and q are not next to each other.

3 Arrange a, a, a, b, b, b, b so that no two a are next to each other.

  1. 1
    5! × 2 = 240
  2. 2
    5! − 4! × 2 = 120 − 48 = 72
  3. 3
    one order of bbbb, five gaps: ⁵C₃ = 10
Tick what you can do now
Practise with m26/52 Q2(a); s26/53 Q6(a); s26/55 Q7(a) (related separation restrictions)
3 / 6
9709 · Unit 25 · Permutations and combinations
Revisionbyexamplicity

Fixed places: spacing, ends and digits

§5.2 · Permutations and combinations

Some rules fix a place: the last digit, the letters at each end, the distance between two letters. Deal with that place first, then fill the free places. If the fixed place has options that change the rest, split into cases and add.

1Spacing between two letters: list the position pairs

Spacing is about numbered places, not a block. List the pairs of places, then fill the rest.
a1·2·3a4·5·6·7·a··a····a··a····a··aEach row fixes the two a positions once.
Worked example

Arrange a, a, b, b, c, c, c with exactly two letters between the two a.

  1. The a places differ by 3
    (1, 4), (2, 5), (3, 6), (4, 7): 4 pairs
  2. Fill the other five places with b, b, c, c, c
    N=5!2!×3! = 10
  3. Answer
    4 × 10 = 40 strings
At least four letters between: pairs (1, 6), (1, 7), (2, 7), so 3 × 10 = 30. Exactly four alone gives only 20.

2Fixed ends: place them before anything else

Worked example

Arrange a, a, b, b, c, c, c with b at both ends and exactly two letters between the two a.

  1. Put b at places 1 and 7
    both b are now used
  2. The a places differ by 3, inside places 2 to 6
    (2, 5) or (3, 6)
  3. The three c fill what is left: one way each
    baccacb, bcaccab
  4. Answer
    2 strings

3Digits: fix the last digit first

Use the digits 0, 2, 3, 5, 7, 8, with no digit repeated. A three-digit number cannot start with 0, and “even” is decided by the last digit. Put 0 in its own case: it changes the first-digit choices.
023578Ending 02H3T0UEnding 2 or 83H5T2U023578Ending 02H3T0UEnding 2 or 83H5T2U
Last digitFirst digitMiddle digitCount
05: 2, 3, 5, 7, 84 left1 × 5 × 4 = 20
24: not 0, not 24, including 01 × 4 × 4 = 16
84: not 0, not 84, including 01 × 4 × 4 = 16
Add the cases: 20 + 16 + 16 = 52 even numbers. They cannot overlap: each has a different last digit.

4Repeats allowed, and multiples of 5

Worked example

Even three-digit numbers from 0, 2, 3, 5, 7, 8, digits may repeat.

  1. First digit not 0; any middle digit; last digit 0, 2 or 8
    5 × 6 × 3
  2. Answer
    90 numbersFor example 222 is allowed now.
Worked example

Multiples of 5 from the same digits, no digit repeated.

  1. Five first digits, four middle digits
    ending 0: 5 × 4=20
  2. First digit not 0 and not 5
    ending 5: 4 × 4=16
  3. Answer
    20 + 16 = 36 numbersAdd the two cases.
Even three-digit numbers from 0, 2, 3, 5, 7, 8, digits may repeat.
5 × 6 × 3First digit not 0; any middle digit; last digit 0, 2 or 8.90 numbersFor example 222 is allowed now.
Multiples of 5 from the same digits, no digit repeated.
ending 0: 5 × 4 = 20Five first digits, four middle digits.ending 5: 4 × 4 = 16First digit not 0 and not 5.20 + 16 = 36 numbersAdd the two cases.

5Try it

Your turn

1 Arrange p, p, q, q, r, r with exactly one letter between the two p.

2 How many odd three-digit numbers can be made from 1, 2, 4, 6, 9 with no digit repeated?

3 How many even three-digit numbers can be made from 0, 1, 3, 4, 6 with no digit repeated?

  1. 1
    pairs (1, 3), (2, 4), (3, 5), (4, 6); 4 × 4!/(2! 2!) = 4 × 6 = 24
  2. 2
    last digit 1 or 9: 2 × 4 × 3 = 24
  3. 3
    ending 0: 4 × 3 = 12; ending 4 or 6: 3 × 3 = 9 each; 12 + 9 + 9 = 30
Tick what you can do now
Practise with m26/52 Q2(b); s26/51 Q5(b), Q5(c); s26/53 Q6(b); s26/55 Q7(b); s26/52 Q3(a), Q3(b)
4 / 6
9709 · Unit 25 · Permutations and combinations
Revisionbyexamplicity

Selections with conditions, and probability

§5.2 · Permutations and combinations

“At least two blue” hides separate cases: exactly two blue, or exactly three. Count each case, then add. To turn a count into a probability, divide by a total counted in the same way.

1Split “at least” into cases

ABCDEFGDisjoint cases for a three-token groupACE2 blue + 1 goldACD3 blue + 0 gold
Worked example

Choose a group of 3 from A–G with at least two blue (A–D are blue, E–G gold).

  1. 2 blue and 1 gold
    (42)×(31) = 6 × 3 = 18
  2. 3 blue and 0 gold
    (43)×(30) = 4
  3. The cases cannot overlap: add
    18 + 4
  4. Answer
    22 groups
✓Check fewer than two blue: 1 + 12 = 13, and 35 − 13 = 22

2Probability: the same kind of count top and bottom

Worked example

Every group of three from A–G is equally likely. Find P(at least two blue).

  1. Favourable groups, from step 1
    22
  2. All groups
    (73)=35
  3. Answer
    P(at least two blue)=2235
✓Check with ordered triples, top and bottom both gain 3!: 132/210 = 22/35
22/210 puts groups on top and ordered triples underneath. Top and bottom must count the same kind of outcome.

3Tiles that look alike are still separate tiles

Seven tiles show a, a, b, b, c, c, c. Draw three: every set of physical tiles is equally likely, but the 8 letter patterns are not.
LettersTile setsCount
aab²C₂ × ²C₁2
aac²C₂ × ³C₁3
abb²C₁ × ²C₂2
abc²C₁ × ²C₁ × ³C₁12
acc²C₁ × ³C₂6
bbc²C₂ × ³C₁3
bcc²C₁ × ³C₂6
ccc³C₃1
a₁a₂b₁b₂c₁c₂c₃Track physical copies for the random draw.Erasing subscripts records only the letters.
  1. The tile sets add up to ⁷C₃
    2 + 3 + 2 + 12 + 6 + 3 + 6 + 1=35
  2. Answer
    P(one of each)=1235One of the 2 a, one of the 2 b, one of the 3 c.
2 + 3 + 2 + 12 + 6 + 3 + 6 + 1 = 35The tile sets add up to ⁷C₃.P(one of each)=1235One of the 2 a, one of the 2 b, one of the 3 c.
There are 8 different-looking selections, but P(abc) is not 1/8: they are not equally likely.

4Split into two groups: choose one, the rest is the other

ACEGroup of 3BDFGGroup of 4Only group membership is recorded.
  1. Choose the group of three; the other four form the group of four
    N=(73)×(44)
  2. Answer
    35 waysNo ÷ 2!: the groups have different sizes, so they cannot be swapped.
N=(73)×(44)Choose the group of three; the other four form the group of four.35 waysNo ÷ 2!: the groups have different sizes, so they cannot be swapped.
With repeated letters, list the contents instead. Split a, a, b, b, c, c, c, d into a group of three and a group of five, with all three c in one group and both a in one group:
Group of threeGroup of fiveWhy
cccaabbdccc fills the small group.
bbdaacccccc and aa fill the large group.
aadbbcccccc large; aa small with d.
aabbcccdccc large; aa small with b.
4 ways. The two b copies do not make two versions of aab.

5Try it

Your turn

1 A group of 4 is chosen from 5 red and 4 green counters, all different. How many groups have at least 3 red?

2 Every group of 4 is equally likely. Find P(at least 3 red).

3 Six tiles show p, p, q, q, q, r. Two are drawn. Find P(both show q).

4 In how many ways can 8 different people be split into a group of 3 and a group of 5?

  1. 1
    ⁵C₃ × ⁴C₁ + ⁵C₄ = 40 + 5 = 45
  2. 2
    45/⁹C₄ = 45/126 = 5/14
  3. 3
    ³C₂/⁶C₂ = 3/15 = 1/5
  4. 4
    ⁸C₃ = 56
Tick what you can do now
Practise with m26/52 Q1; s26/52 Q1(a); s26/51 Q5(a); s26/53 Q6(c); s26/52 Q1(b); s26/55 Q7(c)
5 / 6
9709 · Unit 25 · Permutations and combinations
Revisionbyexamplicity

Two labelled rows

§5.2 · Permutations and combinations

The seven tokens now fill a front row of three seats (F1–F3) and a back row of four (B1–B4). A count has two parts: who sits in each row, and in what order. The order part is always 3! × 4! = 144.

1Split by row

FrontBackF1AF2BF3FB1CB2DB3EB4GOne allowed arrangement: A and B in front.
Worked example

A and B must be in the same row. How many arrangements?

  1. Both in front: seats for A, then B, then the rest
    N=3×2×5! = 720
  2. Both at the back
    N=4×3×5! = 1440
  3. The cases cannot overlap: add
    720 + 1440
  4. Answer
    2160 arrangements

2Members first, then order

Worked example

Count the same arrangements by choosing who sits in each row first. Then find P(same row).

  1. A and B in front: 1 more from the other five. At the back: 3 of the other five go in front
    5 + ⁵C₃=5 + 10 = 15
  2. Order each row
    N=15×3!×4! = 2160
  3. Divide by all 7! = 5040 equally likely arrangements
    P(same row)=21605040
  4. Answer
    P(same row) = 3/7
Do not divide by 2!: the rows are labelled and have different sizes.

3Two conditions at once: one case for each row

Now A and B must be in the same row and at least two blue tokens (A–D) must be in front.
Case 1: A and B in frontFrontBackF1AF2BF3EB1CB2DB3FB4GThird front token:C, D, E, F or GCase 2: A and B at backFrontBackF1CF2DF3EB1AB2BB3FB4GFront must contain C and D,plus E, F or GCase 1: A and B in frontFrontBackF1AF2BF3EB1CB2DB3FB4GThird front token: C, D, E, F or GCase 2: A and B at backFrontBackF1CF2DF3EB1AB2BB3FB4GFront: C, D and one of E, F, G
Worked example

Case 1: A and B in front.

  1. They already give two blue. The third front token is any of C, D, E, F, G
    5 choices
  2. Answer
    N₁=5×3!×4! = 720Order both rows.
Worked example

Case 2: A and B at the back.

  1. C and D must both be in front; the third is E, F or G
    3 choices
  2. Answer
    N₂=3×3!×4! = 432Order both rows.
Case 1: A and B in front.
5 choicesThey already give two blue. The third front token is any of C, D, E, F, G.N₁=5×3!×4! = 720Order both rows.
Case 2: A and B at the back.
3 choicesC and D must both be in front; the third is E, F or G.N₂=3×3!×4! = 432Order both rows.
  1. A and B cannot be in both rows: add
    N=720+432 = 1152
  2. Divide by all complete arrangements
    P(both conditions)=11525040
  3. Answer
    8/35The same as 8 front groups out of ⁷C₃ = 35: the 3! × 4! cancels.
N=720+432 = 1152A and B cannot be in both rows: add.P(both conditions)=11525040Divide by all complete arrangements.8/35The same as 8 front groups out of ⁷C₃ = 35: the 3! × 4! cancels.

4Try it

Your turn

1 A must sit in the front row. How many arrangements?

2 C and D must both sit in the back row. How many arrangements?

3 Find the probability that A and B both sit in the front row.

  1. 1
    3 × 6! = 2160
  2. 2
    4 × 3 × 5! = 1440
  3. 3
    3 × 2 × 5!/7! = 720/5040 = 1/7
Tick what you can do now
Practise with s26/52 Q1(b) (related group assignment); s26/55 Q7(c) (related group cases); m26/52 Q1; s26/52 Q1(a), Q1(b); s26/55 Q7(c) (related combined restrictions)
6 / 6