Three switches outside a windowless room are connected to three lightbulbs inside the room. How can you determine which switch is connected to which bulb if you are only allowed to enter the room once?
Switch on the first switch, leave it for a minute, and then switch it off again. Then switch on the second switch and enter the room. The second switch will be connected to the light that is on, the first switch will be connected to the light with the warm bulb, and the third switch will be connected to the light with the cold bulb.