Friday, September 18, 2020

1000 Lockers Problem

Disclaimer: I have done this problem or similar ones a few times with my tutoring students. 

After all 1000 students are done with their turns, the lockers that are closed are: 1, 4, 9, 16, 25, 36, 49, 64, 81, 100, 121, 144, 169, 196, 225, 256, 289, 324, 361, 400, 441, 484, 529, 576, 625, 676, 729, 784, 841, 900 and 961. 

As you can see these lockers numbers are all perfect square numbers. What is common among these numbers? The number of times they are switched is odd, that is, they are switched odd number of times. 

If a locker is switched for an even number of times, it remains open. Let's take locker #10 as an example. Students # 1, 2, 5 and 10 would have switched the state of the locker: #1 closes it. #2 opens it. #5 closes it and #10 opens it. However, for a perfect square number like 16, students #1, 2, 4, 8 and 16 are the ones who switch the state of the locker: #1 closes it. #2 opens it. #4 closes it. #8 opens it and #16 closes it. As we notice, if the locker is switched even number of times, at the end of the day it will be open. And if the locker is switched odd number of times, it will be closed at the very end. So at the end of the day, 31 lockers will be closed and all the other ones will be open.

As mentioned earlier, I have done this problem with my students. We went through this interesting problem when I was teaching them factors and perfect squares. In the previous paragraph, we know locker #10 is switched by students# 1,2,5, and 10 and these are exactly the factors of 10. So to make it more math related, we say that if the locker# has an even number of factors, it will be open at the end. If the locker# has an odd number of factors, it will be close at the end. And we know that only perfect square numbers have odd number of factors, then we know all the perfect square locker #'s are going to be close at the end of the day.

Of course, when I was working with my students, we did not jump right into this conclusion. This would have taken the fun out of the problem! Usually I asked my students to tackle this problem with a small number of lockers (like 10 lockers). Then they got to walk through the entire of process of opening and closing each and every single locker easily since there were only 10 lockers. Then I would ask them to come up with a conjecture based on their finding for the first 10 lockers (Shown in the picture attached). Once they found out that locker 1,4 and 9 were closed, I would ask them whether they find anything common for these numbers. Once they were on the right track, it was a matter of time before they come up with right answer.

Overall, this is a method of inductive reasoning. The idea behind this is to tackle a math problem using a small sample. Then once you have successfully solved the smaller problem, we can apply the solution to the full problem. 




 


1 comment:

Course Reflection

 I have thoroughly enjoyed this course in this semester. The most rewarding part of the course is witnessing the transformation of myself th...