Brain Teasers
Brain Teasers Trivia Mentalrobics Games Community
Personal Links
Submit a Teaser
Your Favorites
Your Watchlist
Browse Teasers
All

Cryptography
Group
Language
Letter-Equations
Logic
Logic-Grid
Math
Mystery
Optical-Illusions
Other
Probability
Rebus
Riddle
Science
Series
Situation
Trick
Trivia

Random
Daily Teasers
Search Teasers

Advanced Search
Add to Google Add to del.icio.us

More ways to get Braingle...

Prisoners and 2 Switches - Scenario A

Logic puzzles require you to think. You will have to be logical in your reasoning.

 

Puzzle ID:#18012
Fun:*** (2.93)
Difficulty:**** (3.22)
Category:Logic
Submitted By:biztycl**
Corrected By:boodler

 

 

 



The warden meets with 23 new prisoners when they arrive. He tells them, "You may meet today and plan a strategy. But after today, you will be in isolated cells and will have no communication with one another.

"In the prison there is a switch room which contains two light switches labeled A and B, each of which can be in either the 'on' or the 'off' position. BOTH SWITCHES ARE IN THEIR OFF POSITIONS NOW.* The switches are not connected to anything.

"After today, from time to time whenever I feel so inclined, I will select one prisoner at random and escort him to the switch room. This prisoner will select one of the two switches and reverse its position. He must move one, but only one of the switches. He can't move both but he can't move none either. Then he'll be led back to his cell."

"No one else will enter the switch room until I lead the next prisoner there, and he'll be instructed to do the same thing. I'm going to choose prisoners at random. I may choose the same guy three times in a row, or I may jump around and come back."

"But, given enough time, everyone will eventually visit the switch room as many times as everyone else. At any time any one of you may declare to me, 'We have all visited the switch room.'

"If it is true, then you will all be set free. If it is false, and somebody has not yet visited the switch room, you will be fed to the alligators."

*note - the only difference from Scenario B, the original position of the 2 switches are known.



Answer

1. Appoint a "scorekeeper" and the other 22 prisoners as "transmitters".

2. When a transmitter enter the switch room for the first time, he will flick switch B ON if he sees it in the OFF position. Alternatively, he will flick switch A if he sees switch B is in the ON position and waits for his next visit. The transmitter's mission is to find ONE opportunity to flick switch B to the ON position. After he completes his mission, he will flick switch A for all subsequent visits. In short, each transmitter's role is to send a signal to the scorekeeper that he has been to the switch room.

3. The scorekeeper's role is to flick off switch B whenever he sees it in the ON position. Each time he flicks off switch B he adds 1 to his score. When he sees switch B is already OFF, he flicks switch A instead and does not add to the score. As soon as he accumulates 22, he reports to the Warden.

Hide




What Next?

  
  

See another brain teaser just like this one...

Or, just get a random brain teaser

If you become a registered user you can vote on this brain teaser, keep track of
which ones you have seen, and even make your own.

 



Comments

humoeba*
Jun 24, 2004

I like it!!! Cool
jimbo*au*
Jun 26, 2004

Interesting logic but I had in mind something that would take less time. Hope the scorekeeper doesn't die before the strategy carries through.
(user deleted)
Jun 26, 2004

That was weird. I didn't understand what you were asking though.
hersheykiss8908*
Jun 27, 2004

that was really hard, and took a little too much time. i liked it though, and i would have never thought of the answer
crystalstar*
Jun 27, 2004

Hmm...It's okaaaaaaaay, I guess. But yeah, it's basically impossible for anyone to think of the answer to that, and also I didn't know what we had to figure out, so I think you should have made that clearer!
Varthen**
Jul 01, 2004

I dont like people who give me headaches...
rashadAma*
Jul 04, 2004

Ok i liked this 1 but the problem that there was no question...there is no point...the answer may be 15ducj=k and i have the right to say that cuz there is no question make it clearer the next time
kuya_kei
Jul 13, 2004

This is very good. I liked the way it made my head ache.
sakirski*
Jul 13, 2004

Excellent Teaser in my opinion. It's perfectly logical, and it's perfectly solvable, though certainly not very easy.
The question though not stated in the given is implied, so I don't think it to be a big deal that it's missing.
sakirski*
Jul 15, 2004

OK so I just found a problem with the solution (provided the current statement of the given) For the solution to work the prisoners will have to keep visiting the jail cell even after all of them visited it an equal number of times.
You see nowhere in the problem does it say that the warden will keep pulling prisoners into the switch room indefinitely. Problem states that he will pick them randomly, and that everyone will visit the room as many times as everyone else. Well what if the luck of the draw happens that randomly they will all be picked only once and all 23 will visit the room only once? Then the counter can only do one flip of the switch, and then they will never be freed.

So basically the problem needs an extra statement: “Assume that this exercise continues indefinitely until one of the prisoners speaks out.”
swordflame*
Jul 30, 2004

It seems to me that the answer is slightly incorrect. In part 3 of the answer, the second ON should read OFF.
biztycl
Jul 30, 2004

Thanks Sakirski, the pre-condition you mentioned is stated in the hint section. I like those 3 teasers you posted too.
(user deleted)
Aug 16, 2004

super
valeriy*ru*
Aug 24, 2004

Assuming non of the prisoners died in the jail. Then they would stay there 4ever.
gs_navee034
Sep 30, 2004

coooooooooool
stormtrooper*
Feb 13, 2005

wha...wha...wha?
jacstop*
May 11, 2005

As a matter of fact or fiction, this scenario's countless improbabilities bequeath indistinct objectives to its foreseen populace. This is neither bad nor good
netgoof
May 13, 2005

If the warden picked one random prisoner every day, it would take about 596 days on average.
sweetime**
May 16, 2005

I wasn't sure what the question was asking - i was trying to work out how the warden would know if they were lying or not...(for some reason i had a nice double blind going on, and the warden didn't know who he was taking out either...)
(user deleted)
Jul 23, 2005

its too hard & it takes toooooo long
smarty_blondy*ro*
Nov 07, 2005

What exactly are we supposed to find out? What does this teaser ask? I only see plain text with an explanation fallen from the sky.
shenqiangAcn*
Nov 15, 2005

Where is Scenario B?
HibsMax
Feb 28, 2006

Unless I don't understand the problem correctly, I think there is a flaw. For ease let's say that the warden has already decided that he is going to pick each prisoner 5 times. What if the scorekeeper is picked to make the first 5 visits? Who keeps score then?
HibsMax
Feb 28, 2006

Sorry, I'm new here. I guess I should have looked at the date of the problem first.
mercenary007*jm*
Apr 01, 2006

I think this is a nice try... for those of you who say you didn't know what to do then something is wrong with you cuz anyone could figure out that the prisoners should devise a plan to get out... DUH!!!! OBVIOUSLY... now as for the answer... if the scorekeeper counts 1 for every time that he flicks off the switch B that would be incorrect. If 1 prisoner goes before him and flicks B on and then the scorekeeper goes and flicks it off and they alternate like that for 3 turns then the scorekeeper would count 3 when in fact only 1 of his fellow prisoners has been to the room. For this reason the answer is wrong in my mind.
safire2191*us*
Apr 14, 2006

what was the question?
calmsaviorAus*
May 16, 2006

that solution makes a lot of sense...
Creshoskus
Jun 24, 2006

I have to agree with mercenary007. alternating between the scorekeeper and one other person multiple times would ruin the solution.

As it stands the prisoners are alligator chow.
ztodd
Oct 16, 2006

Read the problem again mercenary and cresh. Each transmitter only flips B to on if it's off one time, then only flips A after that, no matter whether they find B off again or not in later visits.
I agree though that it's not totally clear if the warden is guaranteed to keep bring prisoners back or if he will stop after they've all had the same number of turns.
senther7Aus*
Dec 30, 2006

I think THINK that i foud a flaw.

What happened if 2 transmitters go to the room, and neither of them have gone to the room, how does the reciver know that 2 people has gone, not one?Unless someone explaines the tatic, i think the answer is wrong
senther7Aus*
Dec 30, 2006

O wait, never mind
(user deleted)
Jan 07, 2007

question is flawed... you have to assume too much... but i still liked it
jesdexter*us*
Mar 25, 2007

i never knew the question
Odessius
Apr 20, 2007

(sigh) well people, its to the alligators. Theres no way; we could have been in there for a hundred billion years. Still, yeah sure, the answer works out, and I was beat by the puzle... ih. I tried to split em into 2's and 4's with 4 possible combinations, and clubbing the warden, nope wasn't gona solve that one. a transmitter... don't feel bad, a transmitter, dude! okay so what if we're in the planning stage, and someone says what if the transmitter dies. hmm...
notsosmart111Aie*
Jun 11, 2007

OW!!! My head hurts how do you come up with this stuff!!! It's so brilliant!!!
(user deleted)
Jun 13, 2007

Great teaser, very creative.

I was able to come up with the same solution, However, thought that there would be a more efficient one because this solution means pretty much that it will takes them an extremely long time to get out depending on their luck/probability.

Maybe change the number of prisoners to a smaller number. Then again, it is a jail haha
spinnercatAus*
Jul 23, 2007

brilliant!!!!! My math teacher gave this to us, but never told us the answer. Thanks!!!!
974999gecAus*
Oct 26, 2007

How do you come up with this stuff? I mean really! Does it just hit you?
(user deleted)
Jan 11, 2008

I'm going to choose prisoners at random. I may choose the same guy three times in a row, or I may jump around and come back."

and hint B) there are no restrictions to how many times each prisoner can visit the room...

make it impossible for the prisoners to devise a plan that doesnt involve luck.
plokolplokph
May 14, 2008

how 'bout flicking switch B on everytime a prisoner goes into the switch room for the first time, and flicking switch A if he/she already got there...then it's everybody's role to count the ons and offs of light B, because if they appoint only one 'counter', just one missed count could lead to dying old in prison...the counter would never reach 23...or is this what the solution suggests?
ow.
head achy achy...
Sorena888
Nov 06, 2008

Yes it works. Every one could count. This is a better way.
MikeGus*
Oct 31, 2011

I love this teaser.
And I know it's 3 years later, but what plokolplok suggests doesn't work. If you have more than one person who counts, who turns off switch B? Only one person can turn off switch B, otherwise they could be staying in there a LOT longer than they would with the poster's solution. And if one person turns it off, you can't have other people counting; a counter could come in five times in a row, see the switch ON each time and add 5, even though nobody else came in.
YangL21
Jun 14, 2013

I LOVE IT!!!!!!!! (little tricky though. Cut that out. not little, but A LOT!) I still love it though.
MichaelMaverick
Nov 13, 2013

There is no 100% guaranteed solution, and it is in fact entirely hopeless. It's one thing for the warden to offer them a deadly game where he's the judge who doesn't have to play by the rules. But by giving it an element of randomness that only he controls, he's bluntly announcing that it's a trap to get all the prisoners killed. He won't ever pick anyone. It *looks* solvable and he's actually generous to give them a full day to think about it, but they'll probably come up with a flawed plan or nothing at all. Even if in the latter case they agree to do nothing, so long as they don't collectively realize that it's a trick, someone will inevitably try their luck. The idea of freedom is too tempting. Even suggesting to the sadistic warden that no solution exists still carries the risk of death. This puzzle is really creepy when you think about it.
Johnnylloyd
Feb 24, 2014

Why does there not seem to be any logical solution here??? How can you with reasoned analytical deduction solve close to 46 random selections without a way to empirically verify that indeed all have flipped a switch? An electrician knows light switches: there are 4 screws. Electricians set the screw head slot to vertical which indicates 12. The first man sets the screw (top left) to 1 o'clock and men stop at setting 5 and go to bottom screw and do 5 more. 4 screws allow 20 people. When a man comes in and sees all set at 5, he starts over at top left screw. Ergo any man is both the recorder and counter. In this scenario each prisoner must cheat with his fingernail. Subterfuge is a dishonest mans calling. The 23 or 45 or 46 visit or any can be ascertained at any time by any man. All men should know how to tell time. How would any man know when he was 13th . He would simply count.
chemical
Mar 02, 2014

the funny thing is all this thinking is unnecessary, the answer is simple.

they hold their strategy meeting in the "switch room" and they each flip the switch. they are all free as soon as they all get back to their cells and one of them declares they have all been in the room.



Back to Top
   



Users in Chat : eighsse 

Online Now: 21 users and 500 guests

Copyright © 1999-2014 | Updates | FAQ | RSS | Widgets | Links | Green | Subscribe | Contact | Privacy | Conditions | Advertise

Custom Search





Sign In A Create a free account