THE LOCKER PROBLEM
One hundred students are assigned lockers 1 through 100. The student assigned to
locker number 1 opens all 100 lockers. The student assigned to locker number 2 then
closes all lockers whose numbers are multiples of 2. The student assigned to locker
number 3 changes the status of all lockers whose numbers are multiples of 3 (e.g.
locker number 3, which is open gets closed, locker number 6, which is closed, gets
opened). The student assigned to locker number 4 changes the status of all locker
whose numbers are multiples of 4, and so on for all 100 lockers.
locker number 1 opens all 100 lockers. The student assigned to locker number 2 then
closes all lockers whose numbers are multiples of 2. The student assigned to locker
number 3 changes the status of all lockers whose numbers are multiples of 3 (e.g.
locker number 3, which is open gets closed, locker number 6, which is closed, gets
opened). The student assigned to locker number 4 changes the status of all locker
whose numbers are multiples of 4, and so on for all 100 lockers.