Leave switch 1 off all the time. Turn switch 2 on for a couple of minutes, then turn it off. Turn switch 3 on and leave it on. Now, go to the bulb. If the lightbulb is on, switch 3 controls it. Otherwise, if the lightbulb is hot to the touch, switch 2 controls it. Otherwise, switch 1 controls it.
Since incandescent bulbs do not get hot immediately, it is possible to distinguish between four switches. The trick is to turn switch 4 on just before you go into the other room. If the lightbulb is on and hot, than switch 3 controls it, but if it is only warm, then switch 4 controls it.
