100 prisoners and the Light Bulb Puzzle

1,432.4K Views

There are 100 prisoners are in solitary cells, unable to see, speak or communicate in any way with each other. There’s a room with one light bulb, the bulb is initially off. No prisoner can see the light bulb from his own cell. Everyday, the warden picks a prisoner at random, and that prisoner goes to the that room. While there, the prisoner can toggle the bulb if he wishes. Also, the prisoner has the option of asserting the claim that all 100 prisoners have been to the living room. If this assertion is false (that is, some prisoners still haven’t been to the living room), all 100 prisoners will be shot for their stupidity. However, if it is indeed true, all prisoners are set free. Thus, the assertion should only be made if the prisoner is 100% certain of its validity.
Before the random picking begins.All the prisoners are allowed to get together to discuss a plan.
Note that each prisoner can be selected any number of times and the process will continue till the assertion is not made.

Share
Add Comment

  • 2 Answer(s)

    The prisoners need a way to communicate with each other on who when into the cell. Therefore one person is chosen as the counter.
    Every time any prisoner is selected other than counter person , they follow these steps. If they have never turned on the light bulb before and the light bulb is off, they turn it on. If not, they don’t do anything.Now if Counter person is selected and the light bulb is already on, he adds one to his count and turns off the bulb. If the bulb is off, he just sits and do nothing. The day his count reaches 99, he calls the warden and tells him “Every prisoner has been in the special room at least once”.

    pnikam Expert Answered on 22nd August 2015.
    Add Comment
    The prisoners give themselves numbers from 1 to 100 and determine among themselves what each prisoner should do when he leaves.
    Every prisoner whose number is less than 100 turns on the lamp if it is off and on the condition that he has never turned it on yet.
    The prisoner whose number is 100 turns off the lamp if it is on and counts the number of times he turned it off.
    After counting 99 times, he informs the warden that all prisoners have already gone out into the room at least once.
    Moshe Expert Answered on 15th January 2023.
    Add Comment
  • Your Answer

    By posting your answer, you agree to the privacy policy and terms of service.
  • More puzzles to try-