1. Attachments are working again! Check out this thread for more details and to report any other bugs.

Prisoner problems / riddles

Discussion in 'Fred's House of Pancakes' started by PriQ, Apr 14, 2012.

  1. PriQ

    PriQ CT+iQ

    Joined:
    Feb 16, 2010
    377
    113
    0
    Location:
    Europe
    Vehicle:
    Other Hybrid
    Model:
    Two
    Seeing how there are nearly half a thousand replies in the thread for Pascal's probability excercise, I hope to ride the positive momentum of interest in probability theory and discuss some riddles involving prisoners.

    Let me get started with a really simple riddle (I believe this is well known and even features in books like "My friend Thomas"):

    Riddle 0
    A prisoner is held in a room with two guarded doors/exits. Behind one door is freedom, and behind the other is certain death. The prisoner is allowed to ask the guards one (yes/no) question each before choosen which door to open. Unfortunately one guard will lie while the other will ask the question truthfully, but the prisoner does not know who the liar is.
    How does the prisoner survive?

    Riddle 1: 100 prisoners and a lightbulb
    Another well known riddle is the 100 prisoners and 1 light bulb problem.
    Here is a link for the problem and a couple of solutions: 100 Prisoners and a Light Bulb
    Can PC come with better solutions? Remember the prisoners are chosen at random, they should be able to use this fact better than just waiting 3 years.

    Riddle 2: 100 prisoners and 100 boxes
    This is one of my all time favorites.
    The description is found here: 100 Prisoners and 100 Boxes
    See some solutions here: Puzzling Names In Boxes - Science News

    The best solution should blow your mind of how good it is. It sure blew my mind when I heard it. Unfortunately it is incredibly difficult to convince the layman why the solution is so good. Can PC come up with a better argument?

    Feel free to add more riddles. We all love a good riddle.
    Oh, and remember spoiler tags for solutions ;)
     
  2. hyo silver

    hyo silver Awaaaaay

    Joined:
    Mar 2, 2005
    15,232
    1,562
    0
    Location:
    off into the sunset
    Vehicle:
    2004 Prius
    Model:
    N/A
    Oh, is that what that was all about. :rolleyes:
     
  3. HaveNoCents

    HaveNoCents Conservative Tree Hugger

    Joined:
    Dec 31, 2011
    299
    46
    0
    Location:
    Crystal Beach, Texas
    Vehicle:
    2012 Prius v wagon
    Model:
    Five
    If you ask one of the guards what the other guard would say if you asked which door leads to freedom, you then choose the opposite door and you are guaranteed to be right.
     
    1 person likes this.
  4. airportkid

    airportkid Will Fly For Food

    Joined:
    Sep 2, 2005
    2,191
    538
    0
    Location:
    San Francisco Bay Area CA
    Vehicle:
    2005 Prius
    Supermarkets & fast food chains concoct contests all the time that involve collecting tickets or stickers to win prizes. Take the McDonalds Monopoly contest, where one ticket, Boardwalk, wins the grand prize. Only one Boardwalk ticket gets printed.

    I haven't researched this but just tried to work it out logically: would picking up 10 tickets from a single McDonalds or 1 ticket each from 10 different McDonalds yield different probabilities of getting the Boardwalk ticket, or would the probabilities be identical? Assume that all tickets are already distributed to all the McDonalds.
     
  5. daniel

    daniel Cat Lovers Against the Bomb

    Joined:
    Feb 25, 2004
    14,487
    1,518
    0
    Location:
    Spokane, WA
    Vehicle:
    2004 Prius
    Thanks. I knew it was something of the sort, but I was too lazy to draw a diagram to analyse it.

    So allowing you to ask each guard a question is a red herring. You only need to ask one guard one question. Clever.

    However, unrealistic. My experience of prison guards during my six months in federal prison is that they are far too pathological to be as reliable as the riddle claims. Most will lie, but if the truth will hurt a prisoner, they'll make an exception and tell the truth. And they NEVER offer prisoners games in which it is possible to win your freedom. They've got a real bug up their nice person when it comes to making sure prisoners don't get out. Except in the Federal Prison Camps, where there is no perimeter security and prisoners can just walk away if they choose. But to be in an FPC you have to have "out status," which the Bureau of Prisons assigns to prisoners that it has decided can be allowed out of the prison.

    Yes, we actually have "prisons" where the BoP itself has decided that NOBODY in the prison presents any danger to society whatsoever, and that from a security standpoint, everybody can be allowed to leave the prison. Of course, if you do, they'll find you and then put you in a real prison. At FPC Yankton (South Dakota), where I spent the first two weeks of my term, there is just a low picket fence around the property, which you can step over, and no guards at the perimeter. We actually crossed a public street to go to the dining hall and the gym, and we did so without supervision. The only thing keeping us in was the threat that they'd find us and put us in a real prison if we walked away. Several times a day we had to be in our rooms to be counted. And we were locked in at night, and for short periods during count. At FCI Sandstone (MN) there was a chain-link fence topped with a coil of razor wire. And at El Reno (OK) there were two concentric chain link fences and the space between then was filled with razor wire and there were guard towers with machine guns at the corners of the yard, and if you got too close to a fence they'd shout through a loudspeaker "Get back from the fence."

    Assuming the tickets are distributed entirely at random, it makes no difference whatsoever where or when you buy the ten tickets. Ten in a bunch, one at each of 10 locations, or ten from one location at different times, or any combination. Your chances of getting Boardwalk on each purchase are identical. Until the willing ticket is revealed, at which point your chances drop to zero.
     
  6. ETC(SS)

    ETC(SS) The OTHER One Percenter.....

    Joined:
    Oct 28, 2010
    7,674
    6,493
    0
    Location:
    Redneck Riviera (Gulf South)
    Vehicle:
    Other Non-Hybrid
    Model:
    N/A
    ^ These days, the lines are a little blurry between prisons being an instrument of punishment, and a detention facility to segregate dangerous persons from the rest of society. It's not my patch really, but I would think that if a person commits a crime that results in no real 'harm' to 'society' then an administrative punishment.....or at most a little time at the house with an unattractive anklet might be in order.

    Like I said.....it's not one of the top turds on my pile where non-violent and relatively low level crime is concerned. We used to get the occasional protesters when I was in the tennis-shoe Navy, and just having a federal conviction on the records of those that stepped over the line, both figuratively and literally is a just punishment for me. Most of these folks represent little or no danger to the population at large other than perhaps an additional security challenge to guarding weapons and other federal property.
    Having some familiarity with both sides of Daniel's crime, I would have probably just tagged him with a felony conviction and a suspended sentence if I were judge for a day, but that's just me.

    Note to would-be protesters:
    Post 9-11, it’s a little bit more dangerous to do some uninvited gardening on federal property where anything preceded by the word “nuclear” is stored. PLEASE! Just march around the fence with a sign if you have to get the protesting thing out of your system!!!
    Yell at the politicians. Make up lies on political boards.
    Don’t make some 20-something year old service person have to level a loaded weapon at you and work his (or her) way through the shoot/don’t shoot problem!!!!

    Violent criminals?
    Segregation usually takes care of the punishment problem, and for the worst of these my sinful nature tempts me to offer the "lady or tiger" riddle to them and just put tigers behind both doors......but that's not in keeping with my belief system. So… I have to settle with paying "experts" to grapple with the punishment versus redemption challenge.

    YMMV!
     
  7. mmcdonal

    mmcdonal Active Member

    Joined:
    Feb 28, 2010
    666
    98
    16
    Location:
    Columbia MD
    Vehicle:
    2010 Prius
    Model:
    IV
    Riddle 0: Don't leave the room.
     
  8. Corwyn

    Corwyn Energy Curmudgeon

    Joined:
    Mar 6, 2011
    2,171
    659
    23
    Location:
    Maine
    Vehicle:
    2007 Prius
    Model:
    II
    Or until the McDonald's you are buying from, runs out of tickets.
     
  9. daniel

    daniel Cat Lovers Against the Bomb

    Joined:
    Feb 25, 2004
    14,487
    1,518
    0
    Location:
    Spokane, WA
    Vehicle:
    2004 Prius
    FWIW, I've never been charged with a felony. The most I've been charged with was a class A misdemeanor plus a class B misdemeanor. On other occasions it's ranged from a class B misdemeanor all the way down to something called an "infraction," which they told me was a step below a misdemeanor, and treated jurisdictionally much the same as a traffic ticket would be. On a few occasions when I participated in nonviolent civil disobedience I was not even arrested. The Air Force and the cops just ignored us, and after a few hours of protesting, we went home.

    The anti-nuclear movement, though small, is alive and well, though I have not been active in it for a couple of decades. The people who do civil disobedience are typically committed and highly motivated by an understanding that nukes are weapons of indiscriminate mass destruction, weapons that if fired (which the U.S. has demonstrated its willingness to do twice in the past, and states officially that it is willing to do again) would kill hundreds of thousands or millions of innocent civilians while poisoning the landscape for hundreds of miles around.

    Nobody should engage in civil disobedience without understanding the theory of nonviolence, and the possible ramifications of their actions, or without formal nonviolence training. It is not something to enter into lightly. But in my opinion it is fully justified by the bloodcurdling horror of such weapons, and I admire the people still engaging in such protests and willing to accept whatever consequences may follow.
     
  10. PriQ

    PriQ CT+iQ

    Joined:
    Feb 16, 2010
    377
    113
    0
    Location:
    Europe
    Vehicle:
    Other Hybrid
    Model:
    Two
    Wait... this can't be right.
    So your question will be: "will the other guard say he guards the door to freedom"? (I had to reformulate it as a yes/no answer question).

    Let me put up the possibilities, and call the two guards by the names "liar" and "truth":

    Liar in front of freedom: Ask liar: His answer: Yes... OK.
    Truth in front of freedom: Ask liar: His answer: No... OK.
    So far, so good.
    Liar in front of freedom: Ask truth: His answer: No... OK.
    Truth in front of freedom: Ask truth: His answer: Yes... OK.

    Uhm... you have succesfully beaten the riddle. Normally the answer is:
    Ask the first guard if he is a guard to establish who is lying, then ask the other if he is guarding freedom.

    Your answer gets around the problem of having one guard being a liar by ensuring that the question goes through both guards, thus ensuring it's negated. Well played, good sir, well played.
     
  11. ETC(SS)

    ETC(SS) The OTHER One Percenter.....

    Joined:
    Oct 28, 2010
    7,674
    6,493
    0
    Location:
    Redneck Riviera (Gulf South)
    Vehicle:
    Other Non-Hybrid
    Model:
    N/A
    My bad. I thought federal prison = felony.

    Actually, we prefer "launch" or "shoot" to the word 'fire'. Communications are rather important when you're at battle stations, and the word "fire" is easily misunderstood for the "rapid oxidation" kind which would be something of a distraction.
    I'm not going to cross foils with you on the ethics of SIOP. People on both sides have been misrepresenting their half of this argument for almost 70 years now.
    I have been to Hiroshima though.
    Didn't look all that poisoned to me.

    Me too.
    Well...most of them.
    Some of them do really REALLY dumb stuff, buuuuuut that's libs for you! ;)
     
  12. daniel

    daniel Cat Lovers Against the Bomb

    Joined:
    Feb 25, 2004
    14,487
    1,518
    0
    Location:
    Spokane, WA
    Vehicle:
    2004 Prius
    Lots of people make that mistake. Federal prison just means you were sentenced to prison in a federal court. In my case, the state didn't want to prosecute something they saw as basically a non-crime (or a crime of too little significance to be worth the expense of a prosecution and imprisonment).

    Noted.

    There were lots of birth defects, some very serious, for a long time after. I don't think radioactive contamination can be determined by a visual inspection, though.

    There are arguments for and against the atomic bombing of Hiroshima. There are also arguments for and against the bombing of Nagasaki, though I think those are weaker, since Japan had not yet had time to respond. Obviously, I feel the bombings were not justified.

    But my point was that the U.S. has made it clear that it is willing to use such weapons, and is willing to use them against an enemy that does not have them, and is willing to be the first to introduce nuclear weapons into a conflict. To those of us who take the moral position that killing civilians is never justified, this makes nukes a legitimate target for any kind of protest that does not harm the people guarding them. If the guard must face the question "Would I kill an unarmed and peaceful protester to protect a weapon of indiscriminate mass destruction (when that weapon is not under any actual threat from the protester)?" then I think their having to ponder that question is a good thing. Protesters have damaged the exteriors of the silos, though I did not, but the nukes themselves are at no risk of damage under all that steel and concrete.
     
  13. daniel

    daniel Cat Lovers Against the Bomb

    Joined:
    Feb 25, 2004
    14,487
    1,518
    0
    Location:
    Spokane, WA
    Vehicle:
    2004 Prius
    P.S. I have had very scary-looking automatic weapons pointed at me by young guards who looked to me even more scared than I was. Once it was what someone told me was a 50-caliber machine gun, mounted on the top of a contraption that looked like a tank with wheels rather than caterpillar treads. Other times it was what someone told me were M16's, though I'd have no way of knowing what exactly they were. Once, the guards who arrested me had a german shepherd dog. One of them told me "Don't make any sudden moves. This is a military working dog." I never make any sudden moves while being arrested anyway. (Part of my nonviolence training.) Then one of the other guards got between the dog handler and the dog, and the handler chewed the guy out something royal. He said to him, in a voice full of anger and military authority, "Don't you EVER get between me and my dog!" I felt kind of bad for the guy. I like dogs, so I wasn't worried, since I had no intention of becoming violent. But they knew I am nonviolent (we had a long history of protesting there) so I think the dog was an attempt to intimidate me.

    But in all my protests, and in all my arrests, I was never treated discourteously by any of the Air Force guards, and I never spoke rudely or angrily or critically to them. I did speak to them at every opportunity about the moral illegitimacy of weapons of indiscriminate mass destruction. We had a slogan, printed on a huge banner, that distilled our view: "US AIR FORCE: GOOD PEOPLE, BAD PRODUCT." (In North Dakota it's the Air Force that operates the nuclear weapons.)

    Prison guards are another matter. Psychopaths, most of them.
     
  14. PriQ

    PriQ CT+iQ

    Joined:
    Feb 16, 2010
    377
    113
    0
    Location:
    Europe
    Vehicle:
    Other Hybrid
    Model:
    Two
    I knew a prison guard once. He was the nicest guy I have ever met, but on his job he had to be rough, dominating and be totally intolerant to BS.

    He and his 4 year old daughter were killed by a drunk teen driver.
     
  15. daniel

    daniel Cat Lovers Against the Bomb

    Joined:
    Feb 25, 2004
    14,487
    1,518
    0
    Location:
    Spokane, WA
    Vehicle:
    2004 Prius
    I never spoke rudely to the guards, and while some inmates did, most did not. Yet we were subjected to constant insults and verbal abuse. Once when I was in solitary, and not permitted newspapers, a particularly demented guard told me that some anti-nuclear protesters had been shot and killed. I asked for names or details and he claimed not to remember. This could have been friends of mine. It took two weeks for a letter from me to reach friends, and a reply to arrive, telling me that it had never happened. This guard had told me that (possible) friends of mine had been killed, just to make me suffer for a while. To call the man a pig would be an insult to pigs.

    I had never uttered a rude or unfriendly word to this guard, yet he was constantly insulting me. He was the worst, but it was the rare guard who did not insult us on a daily basis.

    Hollywood presents prisons as a place of constant fights and riots where guards have to respond with equal or greater violence. Real prison is nothing like that. Most inmates obey the rules and just want to do their time as easily as possible and offer no resistance or insult to the guards. Yet the guards in the federal prisons I was in -- Yankton (SD), El Reno (Oklahoma), Oxford (Wisconsin), and Sandstone (MN), were for the most part viciously rude, insulting, and generally nasty. Not all of them. I'd say maybe 90%.

    And remember that violent criminals are a VERY small part of the federal prison population! Most of my fellow prisoners had not done anything to hurt anybody.

    Interestingly, while I was in jail (my experience of jails was limited to North Dakota, Yankton SD, and Ashland WI) every guard I encountered was polite. The jail guards I encountered never responded to insults in kind and always respected our basic rights.

    Also interesting is that although I was mostly in low-security prisons (and Yankton was zero security) I did spend a week in a high-security prison (El Reno) while being transferred, and there, most of the guards left us pretty much alone. The guards were nastiest in the prisons where the prisoners were the least dangerous! Typical cowardly bullying behavior: picking on people who will not fight back!

    I'm sorry about your friend and his daughter. Our courts go far too easy on drunk drivers.
     
  16. PriQ

    PriQ CT+iQ

    Joined:
    Feb 16, 2010
    377
    113
    0
    Location:
    Europe
    Vehicle:
    Other Hybrid
    Model:
    Two
    He never spoke about his colleagues, but I suppose it's normal that you will find abuse prison guards. I suppose the job attracts those types.

    I can't remember how much time the driver got, but I suppose that having to live with two lives on your concience, including a little child will haunt you and become a punishment enough in itself.
     
  17. HaveNoCents

    HaveNoCents Conservative Tree Hugger

    Joined:
    Dec 31, 2011
    299
    46
    0
    Location:
    Crystal Beach, Texas
    Vehicle:
    2012 Prius v wagon
    Model:
    Five
    I actually misread the riddle. I thought he was only allowed to ask one question, not one question to each guard. One question to any guard is all you need.

    If you ask either guard how the other guard would answer the question " does the door you are guarding lead to freedom?

    So if you happen to pick the liar and ask the liar how truth will answer the question about his door if truth did have the freedom door then the liar would have to lie and No. Therefore you pick the opposite answer. You really don't need to know if he is lying or not. You just pick the opposite.

    If you happened to ask the truth guard about how the other guard would answer the question then you know the truth guard will tell you that the liar guard will answer yes, so you therefore take the opposite door.

    I guess it would have been easier to say door 1 is freedom. You then ask either guard how the other guard would answer does door number one lead to freedom. If the answer is yes from either take door 2

    Only one question needs to be asked to one guard, and it doesn't matter whether the guard is truth or liar.
     
  18. PriQ

    PriQ CT+iQ

    Joined:
    Feb 16, 2010
    377
    113
    0
    Location:
    Europe
    Vehicle:
    Other Hybrid
    Model:
    Two
    Yes. Congratulations on misreading and beating the riddle ;)

    The British gaming show "Golden Balls" ends with a nice version of the Prisoner's Dilemma:


    I this guy a genious or did he make a mistake in his choice?
     
  19. airportkid

    airportkid Will Fly For Food

    Joined:
    Sep 2, 2005
    2,191
    538
    0
    Location:
    San Francisco Bay Area CA
    Vehicle:
    2005 Prius
    Most assuredly yes. Although in the classic prisoners' dilemma the prisoners are NOT permitted any communication.

    But this contestant was brilliant - and I doubt he made a mistake.
     
  20. PriQ

    PriQ CT+iQ

    Joined:
    Feb 16, 2010
    377
    113
    0
    Location:
    Europe
    Vehicle:
    Other Hybrid
    Model:
    Two
    Yes. It is a variant tuned for entertainment, and fueled by having the contestants backstab each other in the previous rounds

    I agree with you and my reasoning is:
    - If the other guy chooses "split", then we get the scenario as seen in the clip. Everyone wins.
    - If the other guy chose "steal", then there is a great chance for pressing money out of him after the game!



    Consider now that the other guy choses randomly and the whole price is 1.

    If you choose "split", then your expected outcome is:
    1/4+½X (where X is what the other guy would give you after the game)

    If you choose "steal" and keep your word:
    1/4.

    And if steal and are dishonest:
    ½.

    This shows that you should be dishonest, but fortunately the other guy does not choose randomly, so our hero here did the right thing.

    Actually, the best player on this show is probably:
    [ame="http://www.youtube.com/watch?v=tBtr8-VMj0E"]£100,150 Split or steal? - YouTube[/ame]

    I should probably warn people about watching that clip.