Lessons / Quantitative aptitude
Quantitative aptitude · Day 8

Permutation and Combination

Order matters → permutation. Order does not matter → combination. Ask 'would swapping two picks give a different answer?'

Exam weightage: HighAbout 1-2 questions per placement paper. Seen most in TCS NQT, Infosys. All topics

Why this topic matters

How many ways can 3 people stand in a line? Try it: 6. How many ways to pick 2 of them for a team? 3. Arranging and choosing are different questions.

Counting is the engine of probability too. The whole topic: multiply for 'and', add for 'or', use P when order matters and C when it does not.

The counting principle: boxes to fill

If one choice can be made in m ways and the next in n ways, together they can be made in m × n ways (AND means multiply).

Draw a box for each position and write the number of choices in it. Multiply.

5x4x3
President, secretary, treasurer from 5 people: 5 × 4 × 3 = 60 ways
Example 1How many 3-digit numbers can be formed with the digits 1 to 6 if no digit repeats?
  1. Hundreds: 6 choices. Tens: 5. Units: 4.Each used digit is no longer available.
  2. 6 × 5 × 4 = 120.
Example 2How many 3-digit numbers with digits from 0 to 9, repetition allowed?
  1. Hundreds: 9 choices (no 0 in front). Tens: 10. Units: 10.A number cannot start with 0.
  2. 900.

Permutations: order matters

nPr = n! / (n - r)! = n × (n - 1) x ... (r numbers). Arranging all n things: n!.

Identical items: divide by the factorial of each repeat. Arrangements of BANANA = 6! / (3! 2!) = 60.

Items that must stay together: glue them into one block, arrange, then arrange inside the block.

Example 1In how many ways can the letters of LEADER be arranged?
  1. 6 letters, E twice.Repeated letters make some arrangements identical.
  2. 6! / 2! = 360.
Example 2In how many arrangements of the word APPLE do the two Ps come together?
  1. Glue PP into one block: A, PP, L, E = 4 items.Together means one block.
  2. 4! = 24.The two Ps are identical, so no inside arrangement.
  3. 24.

Combinations: order does not matter

nCr = n! / (r! (n - r)!) = nPr / r!. Teams, committees, handshakes, groups: choosing, not arranging.

nCr = nC(n - r): choosing 3 to play is the same as choosing 7 to sit out of 10.

Example 1A committee of 3 men and 2 women is to be chosen from 6 men and 5 women. How many ways?
  1. Men: 6C3 = 20. Women: 5C2 = 10.Choose each group separately.
  2. 20 × 10 = 200.
Example 2At least one woman: a team of 3 from 4 men and 3 women.
  1. All teams: 7C3 = 35.
  2. No women: 4C3 = 4.'At least one' → total minus none.
  3. 35 - 4 = 31.

Circles and restrictions

n people around a table: (n - 1)!. Fix one person; arrange the rest. Necklaces and garlands that can be flipped: (n - 1)!/2.

Two people must NOT sit together: total - (arrangements where they are together).

Example 1In how many ways can 6 people sit around a round table?
  1. Fix one person. Arrange 5 others.Rotations of the same seating count once.
  2. 5! = 120.
Example 25 people in a row. Two of them, A and B, refuse to sit together. How many ways?
  1. All: 5! = 120.
  2. A and B together: glue them, 4! x 2! = 48.The block can be AB or BA.
  3. 120 - 48 = 72.

Repetition and restrictions

Repetition allowed: each box has all the choices again. A 4-digit PIN has 104 = 10,000 options.

A restriction on one position ('must start with a vowel', 'must be even'): fill that box FIRST, then the others.

Example 1How many 4-digit even numbers can be made from 1, 2, 3, 4, 5 without repetition?
  1. Units must be 2 or 4: 2 choices. Fill it first.The restricted box goes first.
  2. Remaining boxes: 4 × 3 × 2.
  3. 2 × 24 = 48.
Example 2How many 3-letter codes can be made from 26 letters if letters may repeat?
  1. 26 choices in each box.Repetition allowed.
  2. 263 = 17,576.

Formula summary

Counting principle
Independent steps multiply (AND); alternatives add (OR).
nPr = n!/(n - r)!
Arrangements.
nCr = n!/(r!(n - r)!)
Selections.
Repeated letters
n!/(p! q! ...).
Circular
(n - 1)!. Necklace / garland (can flip): (n - 1)!/2.
Items together
Glue them into one block, arrange, then arrange inside the block.
At least one of n items
2n - 1.
Handshakes / lines
nC2. Diagonals of an n-gon: nC2 - n.

Shortcuts and tricks

Glue the block

Use it when: 'Vowels together'.

  1. ORANGE: vowels O, A, E become one block.
  2. Arrange 4 things: 4!. Inside the block: 3!.
  3. 24 × 6 = 144.
ExampleArrangements of ORANGE with vowels together
  1. 144.

Common mistakes

Using P for a committee.
Committees have no order: use C.
Forgetting that a number cannot start with 0.
Count the first box separately.

Before you move on, you should be able to...

  • draw boxes and multiply
  • choose P or C by asking 'does order matter?'
  • handle repeats, blocks, circles and 'not together'

Practice questions (15)

Try each one before opening the solution. Or practise them one by one so your score is saved.

easy Arrangements of the letters of LEADER?
  1. 6!/2!.

Answer: 360

easy A committee of 3 men and 2 women from 6 men and 5 women?
  1. C(6,3) × C(5,2).

Answer: 200

easy Ways to seat 6 people round a table?
  1. 5!.

Answer: 120

easy Arrangements of BANANA?
  1. 6!/(3! 2!).

Answer: 60

easy Number of diagonals in a decagon?
  1. C(10,2) - 10.

Answer: 35

medium 4-digit numbers with no repeated digit?
  1. 9 × 9 × 8 × 7.

Answer: 4536

hard In how many ways can 5 boys and 3 girls sit in a row so that no two girls sit together?
  1. Seat boys: 5!. 6 gaps, pick and order 3: 6P3 = 120.
  2. 120 × 120.

Answer: 14,400

hard A team of 5 is chosen from 7 men and 4 women with at least 2 women. Ways?
  1. 2W: 6 × 35 = 210. 3W: 4 × 21 = 84. 4W: 1 × 7 = 7.

Answer: 301

hard Arrangements of the letters of MATHEMATICS?
  1. 11!/(2! 2! 2!).

Answer: 49,89,600

hard In how many ways can 5 letters go into 5 addressed envelopes so that none is in the right one?
  1. Derangements: 5!(1 - 1 + 1/2 - 1/6 + 1/24 - 1/120) = 44.

Answer: 44

hard 5 boys and 5 girls sit in a row, alternating. Ways?
  1. Start with B or G: 2 × 5! x 5!.

Answer: 28,800

hard 12 points, 5 of them on one line. How many triangles?
  1. C(12,3) - C(5,3) = 220 - 10.

Answer: 210

hard Choose 4 from 10 people so that 2 particular people are always in. Ways?
  1. C(8,2).

Answer: 28

advanced In how many ways can the letters of ENGINEERING be arranged so that all the vowels come together?
  1. Vowels: E, I, E, E, I (E × 3, I × 2). Consonants: N, G, N, R, N, G (N × 3, G × 2, R).Sort the letters first.
  2. Glue the vowels into one block: 6 consonants + 1 block = 7 items, with N × 3 and G × 2: 7!/(3! 2!) = 420.The block counts as one item.
  3. Inside the block: 5!/(3! 2!) = 10.Repeated vowels inside.
  4. 420 × 10 = 4,200.

Answer: 4,200

advanced In how many ways can 5 identical balls go into 3 different boxes if no box may be empty?
  1. Stars and bars with at least one each: (5 - 1)C(3 - 1) = 4C2.Place 2 dividers in the 4 gaps between the balls.
  2. = 6.

Answer: 6

Class plan (2 hours, for trainers)

A tested order for teaching this topic in one 2-hour session. Present mode follows the same order.

10 minWarm-up: factorials cheat sheet.
20 minBoxes: the counting principle.
25 minPermutations, repeats, glue blocks.
25 minCombinations, committees, 'at least'.
15 minCircles and 'not together'.
20 minPractice set.
5 minRecap.