• Welcome to Computer Association of SIUE - Forums.
 

Riddles, Brain Teasers, and more...

Started by Tony, 2008-12-16T19:38:05-06:00 (Tuesday)

Previous topic - Next topic

Tony

With finals going on and the horrible weather, I thought maybe we could all throw out a few riddles, brain teasers, kewl interview questions or whatever out there to give us a break.  I have one, I am sure a lot of you have heard it, so if you have give it some time before you post it so other people can try to figure it out.  If you have any of your own, feel free.

Riddle:  You are walking down a road in the middle of the desert (I don't know why), and come to a fork in the road.  There is a sign there that says "One road leads to your certain death (no way around this if you take this road), and the other leads you to salvation.  There are two men here, one always lies, and the other always tells the truth.  They both know the correct road to take, but you can only ask one question to one of the men of your choosing."  If you ask one person you cannot ask the other person just to be clear.  Only one question.  What would be the question in which the answer would tell you the path that will leave you to safety?
I would rather be hated for doing what I believe in, than loved for doing what I don't.

William Grim

#1
Hmm, I know the answer, but I then realized I should give it more time before posting.  Oops!
William Grim
IT Associate, Morgan Stanley

Tony

I figured you would probably either get this one, or know it already lol.
I would rather be hated for doing what I believe in, than loved for doing what I don't.

Tangent Orchard

I think this is like an exam question in the logic portion of MATH 224; a lot more people may know it than you think. ^_^;

Mark Sands

Please no more 224. I have the final tomorrow and my head hurts. :\

BTW, you ask one "If you were the other guy, would you tell me the left path leads to salvation?"

Arbitrarily picking left, both will say NO if the left path is the correct path, or YES if right is the correct path! :)
Mark Sands
Computer Science Major

Mark Sands

I'll go ahead and ask the next puzzle..if I may do so

There are 5 houses in 5 different colors. In each house lives a person with a different nationality. The 5 owners drink a certain type of beverage, smoke a certain brand of cigar, and keep a certain pet. No owners have the same pet, smoke the same brand of cigar, or drink the same beverage.

Somebody owns a fish. The question is: who?

Hints
    * The Brit lives in the red house.
    * The Swede keeps dogs as pets.
    * The Dane drinks tea.
    * The green house is on the left and next to the white house.
    * The green homeowner drinks coffee.
    * The person who smokes Pall Mall rears birds.
    * The owner of the yellow house smokes Dunhill.
    * The man living in the center house drinks milk.
    * The Norwegian lives in the first house.
    * The man who smokes Blends lives next to the one who keeps cats.
    * The man who keeps the horse lives next to the man who smokes Dunhill.
    * The owner who smokes Bluemaster drinks beer.
    * The German smokes Prince.
    * The Norwegian lives next to the blue house.
    * The man who smokes Blends has a neighbor who drinks water.
Mark Sands
Computer Science Major

William Grim

Quote from: Mark Sands on 2008-12-18T00:31:04-06:00 (Thursday)
Please no more 224. I have the final tomorrow and my head hurts. :\

BTW, you ask one "If you were the other guy, would you tell me the left path leads to salvation?"

Arbitrarily picking left, both will say NO if the left path is the correct path, or YES if right is the correct path! :)

In that case, if you had chosen the correct path, the liar will tell you it's the wrong path, but the honest one will tell you it's correct.

You need to ask one of them, "Which path would the other person tell me to take?" in order to XNOR them.  Then take the opposite path.
William Grim
IT Associate, Morgan Stanley

Tony

Quote from: Tangent Orchard on 2008-12-17T23:41:19-06:00 (Wednesday)
I think this is like an exam question in the logic portion of MATH 224; a lot more people may know it than you think. ^_^;

I know, that is why I said many of you might already know this.  I just wanted to get something started lol.
I would rather be hated for doing what I believe in, than loved for doing what I don't.

Tony

Quote from: William Grim on 2008-12-18T01:30:02-06:00 (Thursday)
In that case, if you had chosen the correct path, the liar will tell you it's the wrong path, but the honest one will tell you it's correct.

You need to ask one of them, "Which path would the other person tell me to take?" in order to XNOR them.  Then take the opposite path.

Mr. Grim is correct.  If the person you asked was the liar, he has to tell you the path the truthful person will tell you, however he has to lie so he will tell you the wrong one.  Then, the person who cannot lie will have to tell you the path the liar with tell you.  Since the liar has to lie, the truthful person will tell you the wrong path as well.  So, either way you just go the opposite way they tell you.

Or as Grim put it so elegantly, this question will XNOR them.
I would rather be hated for doing what I believe in, than loved for doing what I don't.

Tony

Quote from: Mark Sands on 2008-12-18T00:46:02-06:00 (Thursday)
I'll go ahead and ask the next puzzle..if I may do so

There are 5 houses in 5 different colors. In each house lives a person with a different nationality. The 5 owners drink a certain type of beverage, smoke a certain brand of cigar, and keep a certain pet. No owners have the same pet, smoke the same brand of cigar, or drink the same beverage.

Somebody owns a fish. The question is: who?

Hints
    * The Brit lives in the red house.
    * The Swede keeps dogs as pets.
    * The Dane drinks tea.
    * The green house is on the left and next to the white house.
    * The green homeowner drinks coffee.
    * The person who smokes Pall Mall rears birds.
    * The owner of the yellow house smokes Dunhill.
    * The man living in the center house drinks milk.
    * The Norwegian lives in the first house.
    * The man who smokes Blends lives next to the one who keeps cats.
    * The man who keeps the horse lives next to the man who smokes Dunhill.
    * The owner who smokes Bluemaster drinks beer.
    * The German smokes Prince.
    * The Norwegian lives next to the blue house.
    * The man who smokes Blends has a neighbor who drinks water.

It is the Norwegain who lives in the Yellow house, that smokes Dunhill Cigs, and drinks water
I would rather be hated for doing what I believe in, than loved for doing what I don't.

Tony

Just to see if I am right, this is what I have for everyone.  They are in order of whole lives next to who, left to right.  Norwegian being the furthest left and Swede being furthest right.

Nationality             House Color                Gigs               Drink                Pet
Norwegian                 Yellow                   Dunhill             water               fish
Dane                           Blue                      Blends             tea                  horses
Brit                               Red                     Pall Mal            milk                  Bird
German                       Green                  Prince               coffee              cat
Swede                        White                   Bluemaster      Beer                 Dog
I would rather be hated for doing what I believe in, than loved for doing what I don't.

blacklee

Tony, "The man who smokes Blends lives next to the one who keeps cats." ...???

Mark Sands

Quote from: William Grim on 2008-12-18T01:30:02-06:00 (Thursday)
In that case, if you had chosen the correct path, the liar will tell you it's the wrong path, but the honest one will tell you it's correct.

Nope. My way works.  The liar will say "no the truthteller won't tell you the left path is correct!"  because he's lying.. and the truthteller will say "no the liar won't tell you the left path is correct" because the liar lies of course. Reversal if left is actually the wrong path. But whatever.
Mark Sands
Computer Science Major

Mark Sands

@Tony you were very close, you had the Norwegian and the German switched on pets. but the answer is the German. (Also this riddle is known as Einsteins riddle)

Nationality             House Color                Gigs               Drink                Pet
Norwegian                 Yellow                   Dunhill             water               cat
Dane                           Blue                      Blends             tea                  horses
Brit                               Red                     Pall Mal            milk                  Bird
German                       Green                  Prince               coffee              fish
Swede                        White                   Bluemaster      Beer                 Dog
Mark Sands
Computer Science Major

Tony

Man, I don't know what I did wrong.  I will have to go through it again and see.  I know I probably just got ahead of myself and put something in the wrong spot near the end that threw me off.  Oh well.  Good riddle though.  Crazy how I got everything right but got them mixed up on their pets lol.
I would rather be hated for doing what I believe in, than loved for doing what I don't.