100 prisoners were put in prison. The warden told them:
“I will give you an evening to talk with each other, and then I will put you in separate cells, and you will no longer be able to communicate. Sometimes I will take one of you to a room in which there is a lamp (at first it is off). When leaving the room, you can leave the lamp on or off.
If at some point one of you tells me that you all have already been in the room, and will be right, then I will let you all go free. And if wrong - feed all the crocodiles. And do not worry that someone will be forgotten - if you are silent, you will all be in the room, and for anyone no visit to the room will be the last. ”
Come up with a strategy to ensure the release of prisoners.
')
Thanks gimlis and the_ghost.
Task
from here . According to the link decision)