The Prisoners and the Switch

Prisoners and the SwitchTen prisoners are being held in separate cells. Periodically, one of the prisoners is taken individually to a room containing a switch that can be turned on or off, but does not control anything. The prisoner may turn the switch on or off, or do nothing. Before any of the prisoners visited the room, the switch was in the off position. Some prisoners visit the room more than once, before other prisoners have visited the room at all, and they are not aware of each other’s visits. The ruler has decreed that when any one prisoner is certain that all the prisoners have visited the room, he may say so. If he is correct, all the prisoners will be released. If he is incorrect, all the prisoners will be executed.

You have one opportunity to give a single set of instructions to each of the prisoners, to help them determine with certainty when all of them have visited the room. What do you tell them?

The Answer

See Answer
Tell the prisoners this: Each of you should consider yourself to have one “point.” Whenever you enter the room, you may do nothing, or you may “take” a point by turning the switch off, or “leave” a point by turning the switch on. Whenever one of you has collected ten points, you will know that all of you have visited the room.

 

One thought on “The Prisoners and the Switch”

Leave a Comment (it will be moderated and won't appear immediately)