Thursday 7 April, 2005

Lock your lockers

Filed under: Numbers and stuff

Assume there are 100 lockers lining one wall of your traditional American high-school corridor. All of them are closed. Now you have 100 students. Student number 1 goes along the wall opening every locker whose number is divisible by 1 - i.e. all of them. Student 2 then follows him/her, closing all of the lockers whose numbers are divisible by 2 (i.e. every other locker). And each student follows in turn, changing the state of the lockers whose numbers are divisible by their name-tags (opening any that are closed, and closing any that are open).

How many will be open when the 100th student is done. What would be the answer if there were 10,000 students and 10,000 lockers?

Answer tomorrow, unless someone posts the response beforehand...


Posted by dan at 9:17am | Permalink | Comments (0) | Trackbacks (0)
Comments
Add comment (all comments are currently moderated)
Your name*
Enter the confirmation code* authimage
Comments *



* denotes a mandatory field