Please help me identify these 100 light bulbs by turning ON and OFF their switches.
I have a very peculiar room in my house. It's a simple room that doesn't have much decoration. However, I do have 100 light bulbs hanging from the ceiling because I thought it would look cool. When I installed the 100 light bulbs I wanted maximum freedom, so I also installed 100 independent switches:
Of course I was completely silly, so I installed the switches in a room that is far from the room with the light bulbs and I completely forgot which light switch controls which light bulb. How can I identify which switch controls which light bulb in the least amount of trips possible?
For example, I could flip ON a switch and then go verify which light bulb turned ON, and I could do this for the 100 light bulbs... But that would take me 100 trips.
Give it some thought!
If you need any clarification whatsoever, feel free to ask in the comment section below.
Congratulations to the ones that solved this problem correctly and, in particular, to the ones who sent me their correct solutions:
Know how to solve this? Join the list of solvers by emailing me your solution!
I'll post the solution here once this problem has been live for 2 weeks, which will be around the 10th of April.
Don't forget to subscribe to the newsletter to get bi-weekly problems sent straight to your inbox.
If you enjoyed this blog article, you will love the mathspp insider 🐍🚀 newsletter! Join +16.000 others who are taking their Python 🐍 skills to the next level! 🚀