Reasoning · Grade 5-1 Applications of Prime Factorization

Problem

Lockers left open by divisor-count parity

Ten lockers numbered 1 to 10 all start closed. Student n flips every locker whose number is a multiple of n. Ten students walk past in turn. Find which lockers end up open.
Your answer
How to solve
Strategy Make a Systematic List — Chasing all ten students one after another means keeping track of a hundred visits, which is easy to lose count of. Instead I follow one locker at a time and ask a much smaller question: which students touch this particular locker? Student k touches locker n exactly when k is a divisor of n, so the number of flips a locker receives is simply its number of divisors. Once that is set up, a systematic list of divisor counts for 1 to 10 answers everything, and looking at which counts come out odd reveals the pattern — the open lockers are precisely the square numbers, which I can then explain by pairing divisors up.
1STEP 1

Work out who touches a given locker

The students who visit are the divisors of that number.

6 = 1 × 6 = 2 × 3 → students 1, 2, 3, 6
2STEP 2

Count the flips for every locker

Count the flips for each locker.

1{:}1, 2{:}2, 3{:}2, 4{:}3, 5{:}2, 6{:}4, 7{:}2, 8{:}4, 9{:}3, 10{:}4
3STEP 3

Decide open or closed from the flip count

Starting closed, it needs an odd number of flips.

closed → open → closed → open …
4STEP 4

Pick out the odd counts

The odd counts are lockers 1, 4 and 9.

1, 3, 3 are odd → lockers 1, 4, 9
5STEP 5

See why 1, 4 and 9 are special

Only these are squares, so only they have odd divisor counts.

1 = 1 × 1, 4 = 2 × 2, 9 = 3 × 3
6STEP 6

Spot-check by replaying the students

Replaying locker 4 shows it really is open.

locker 4: open → closed → open
Answer
1, 4, 9 lockers
1 × 1, 2 × 2, 3 × 3
The answer is a set of locker numbers, all of them between 1 and 10 as they must be, and only 3 of the 10 lockers finish open — a modest number, which fits the fact that most numbers have an even count of divisors that cancels out. Locker 1 is open because only one student ever touches it, which is obviously right. The result matches the square-number rule exactly, and a direct replay of lockers 4 and 6 confirmed both an open case and a closed case. Nothing here suggests an off-by-one slip.
Takeaway

A door ends up open only if it was flipped an odd number of times, and that happens only for square numbers — 1, 4 and 9 — because every other number's divisors pair up perfectly.

  • Work out who touches a given locker
  • Count the flips for every locker
  • Decide open or closed from the flip count
  • Pick out the odd counts
  • See why 1, 4 and 9 are special
  • Spot-check by replaying the students