Numsprite數靈精Play free
中文

Maths olympiad question · P5–P6★★★★ Expert

Combinations: olympiad question 7

An expert question on combinations for P5–P6, with a step-by-step solution, diagrams and the answer. Counting arrangements and choices appears in the Hua Xia Cup from the P1 and P2 first rounds to the P5 finals.

The question

For the class photo, 4 boys and 4 girls, all different people, stand in one row.

No two girls may stand next to each other.

Ming and Keung, two of the boys, must not stand next to each other.

How many different orders are possible?

Show the hints (3)
  1. Hint 1: Girls can't be neighbours. Whom is it easier to place first?
  2. Hint 2: "Not next to each other" is hard to count directly. Count every order ignoring Ming and Keung, then take away the ones where they are together.
  3. Hint 3: When Ming and Keung are together no girl stands between them, so the girls have only 4 gaps.

Worked solution

Have a go first, then read the solution step by step.

  1. 1.Ignore Ming and Keung first: the boys line up in 4 × 3 × 2 × 1 = 24 ways; 4 boys leave 5 gaps, and the girls each take one: 5 × 4 × 3 × 2 = 120. In all 24 × 120 = 2880.
  2. 2.Now count the orders with Ming and Keung next to each other: tied together as one, 3 "people" line up in 3 × 2 × 1 = 6 ways, times 2 for swapping them; no girl may stand between them, so there are only 4 gaps: 4 × 3 × 2 × 1 = 24. In all 6 × 2 × 24 = 288.
  3. 3.Apart = all − together: 2880 − 288 = 2592.
  4. ⚠️Common mistake: keeping Ming and Keung apart in the boys' line first (24 − 12 = 12 orders) and then adding the girls, getting 1440. Two boys side by side in the boys' line are apart once a girl stands between them, and those orders are missed.

Answer: 2592 orders

Play more like this in Numsprite (unlimited questions, instant marking) →A free maths game: every level free from Easy to Expert (★ to ★★★★), unlimited questions, no download