Well done, but can you solve it with a twist?

You are traveling alone in the woods, and are lost. On the verge of dehydration, you come across 2 doors. Standing in the way of the 2 doors are 4 trolls. There is a sign hanging above them:

“Behind one of these doors, is death. Behind the other, is freedom. You MUST choose a door. Guarding the doors are 4 trolls. One troll will always lie. Another will always tell the truth. The 2 remaining trolls alternate between telling the truth and lying (If the last question one of them got asked resulted in him lying, then the next question will result in him telling the truth). You may ask 1 question. You can ask it one troll, 2 trolls, 3 trolls or all 4 trolls. Then, you may choose your door. Think carefully.”

What question can you ask and to how many trolls do you ask it to, that will result in your freedom?

Or is it impossible to extract the information you need with this scenario?

I can get it asking just one troll one question:

“If he (pointing to one of the other trolls) were to ask her (pointing to a third) what it (pointing to the fourth) would say the result of your questioning her as to what it would say his response to ‘Which door leads to freedom?’ is, what would he say the answer is?” and take whichever door the troll tells you.

Put simply, this goes through each of the trolls twice. Every time it goes through a lying troll, the answer gets swapped, and it’ll always get swapped an even number of times - 2, 4, or 6, depending on the situation, and how the trolls’ logic works, exactly.

Another way to do this (I just realized) that might be easier is to go through one troll four times:

“How would you respond if I asked you what you would say if I were to inquire, ‘Which door leads to freedom?’?”

I made this question up myself, assuming that there was NO POSSIBLE answer to it. Are you sure your method works though? Because what if the two trolls who alternate between lying and truth telling either:

  1. Both lie
  2. Both tell the truth
  3. One lies, one tells the truth

Wouldn’t that alter the final answer you get?
Is there any way you can explain this a bit better?

I’ve got a tougher one:

What number am I thinking of?

:rolleyes:

Am I missing something? I’ve always thought that all games such as this can be settled by asking any single troll / guardian thing, “If I had asked you yesterday which door leads to freedom / wealth / hot monkey love / salvation, what would you have told me?” Seems to me that you could then use the door that he / she / it tells you. Why does it ever need to be any more complicated?

Sure. The thing of it is, I’m not asking any one troll anything just once. Think of it like this. If you have one gremlin that always lies, then if you asked it, “Are you a gremlin?” then the answer would be No. So, if you asked it, “If I asked you, ‘Are you a gremlin?’, what would you say?” then it would say “Yes” - it lies as to what the false answer is. Sort of like a double negative; it cancels itself out.

Now, that’s the easy part. That trick would work on a gremlin that always lies or always tells the truth. But what if it’s a variable gremlin? Its sequence of truth-telling alternates. So, if you asked it “If asked you, ‘Are you a gremlin?’, what would you say?” then it would respond “No”. It either lies and then tells the truth, or tells the truth and then lies. I guess you could represent it like this:

Possibility 1: ±
Possibility 2: -+

Either way, there’s an odd number of -'s, so the answer will come out being negative. If there were an even number of -'s, they’d cancel each other out, and the final answer would be positive.

Now, how do you take care of this? You ask a thrice-embedded question - it’s like asking it four times, instead of just two, as in that last solution I gave. Sort of like this:

“If I asked you, ‘If I asked you, “If I asked you, ‘Are you a gremlin?’ what would you say?” what would you say?’ what would you say?”

Now we have the following two possibilities:

±±
-±+

Similarly, if you asked a pure truth-telling gremlin, or a pure lying gremlin, a thrice-embedded question, you’d get this:

++++

So, no matter which of the four possibilites it is, there’s an even number of -'s, so the final answer will be the truth, Yes. I know this isn’t simple, so if it’s still not clear what I’m trying to say, let me know where you get lost. Also, if you do understand, and you see a flaw in it, just say so - I just made this up, so I’m not dead certain about it. :slight_smile:

Maybe I need more mescaline to be able to understand this thread.

I understand what your’re saying, but I think you’re wrong. I think the answer to your question “If asked you, ‘Are you a gremlin?’, what would you say?” will always be yes for the switching gremlins. You never actually asked him ‘Are you a Gremlin’, so he won’t switch.

If he was set to lie, the Gremlin’s answer to ‘Are you a gremlin’ would be ‘No’, but you never ask him the question. When you ask him what he would say, he lies and says ‘yes’.

Likewise, if he was going to tell the truth, his answer to ‘Are you a Gremlin’ would be ‘yes’, and when you ask him what he would say, he tells the truth, and says ‘yes’.

Of course, then the solution is even easier: Ask one troll “If I had asked whether door #1 was the door to freedom, would you have said ‘Yes’?” if it says ‘yes’, it’s the door to freedom.

I agree with Achemar’s second answer, but not the first. The first answer goes through each troll once, and there’s no telling what you’d get.

Maybe I can explain Achemar’s logic this way:

Start with Hyptothetical Question Q:“If I asked you twos hours ago which door to take, what would you have said?” And assume door A is the correct door.

The Truth teller would tell truth (A)
The Liar would lie twice and be at truth (A)
The Alternators would be either Lie-Truth (B-B) or Truth-Lie(A-B) but in either case would lie.

Now Hypothetical Question P: If I had asked you question Q an hour ago, what would you have said?

Truth teller is still always true, says A.
Liar would have answered A two hours ago, so now lies and says B.
ALternator (Lie-Truth) would have said B, but now Lies (Lie-Truth-Lie) and says A.
Alternator (Truth-Lie) would have said B, but now tells truth (Truth-Lie-Truth) and says B.

OK… now, if you ain’t befugged by now, the REAL question that you ask is question R: “IF I had asked you question P five minutes ago, what would you have said?”

The truth teller sticks with A.
The Liar would have answered question P by saying B, so now lies and says A.
Alternator (Lie-Truth-Lie) would have answered question P by saying A, but now is in truth mode (Lie-Truth-Lie-Truth) and says A.
ALternator (Truth-Lie-Truth) would have answered question P by saying B, but now lies (Truth-Lie-Truth-Lie) and says A.

SO, you ask question R of any one troll, and you will get a (somewhat convulted but) truthful answer.


Manta, if you want more variations on this, please stick to this topic rather than start a new topic?

I don’t think the alternating gremlins can answer “what would you say” questions in a meaningful way–they don’t have enough information to accurately lie or tell the truth.
“Are you a gremlin?” Alternator answers “yes” or “no” based on his veracity phase.
“If I asked you if you were a gremlin, what would you say?” Truth phase–“I don’t know. When are you going to ask me?”
Lie phase–Dumb look. He can’t say “I don’t know” because it’s true, and he can’t say “yes” or “no” because either one might not be a lie.

I think this also applies to “what would you say” questions about the doors as well. You might solve it by changing it to “What would you say if I could ask you this as a second question:<Insert question>”

ZenBeam, what you said about the variable gremlins switching or not is valid, but my answer was designed to accomodate them, no matter which way it worked out. You’ll notice in my first post that the exact method of getting the answer depends on “how the trolls’ logic works, exactly”. But no matter which way it works, both of my answers should be valid. Now, if you knew with certainty that they didn’t switch on hypothetical questions, then yes, it would be simpler.

I think CKDextHavn explains my logic pretty well, and I agree with everything posted, except that my first answer should also be valid, because it goes through each troll twice, not once. I realize that the language makes this hard to discern and maybe even ambiguous, but that’s what I wrote it as. Thanks, for clearing up my reasoning. (By the way, though, the name is ACHERNAR).

Balance, you’ve got a good point. The most difficult part of this problem is probably not figuring out what you want to ask, but how to phrase your question, and I think you’ve got a pretty decent phrasing there.

How about this, asked of any number of trolls:

‘If, instead of asking this question, I had asked you “which door leads to freedom”, which door would you have indicated?’

(Providing I’m interpreting the alternation rules correctly)

My main probelm with Achernar’s first question is that the problem doesn’t stipulate that the Trolls know the other trolls’ identity and responses.

Achernar’s second question reads as only three questions to me, which wouldn’t work as the ±+ would lie. I’d parse it as:

‘How would you respond if I asked you’ →
‘what you would say if I were to inquire’ →
‘“which door leads to freedom?”’

Oh, and sdimbert: if you want a tough pseudoriddle, go with a classic: What have I got in my pocket? :slight_smile:

The OP does not indicate that any of the trolls know which door is which. What if the truth-telling troll answered your question ‘I don’t know?’ What would you do then?

… or what if none of them spoke English?

Yeah, and what if “Death” is written on one door and “Freedom” is written on the other?

Anyway, once again, (Tim), you’ve shown yourself to be highly perceptive. My second question was originally only double-embedded, not triple-embedded. Sorry for all the confusion. It’s what I was saying about how it may be easy to come up with a concept, but hard to verbalize it.

Also, your problem with my first question is valid, because I had to assume, but I think my assumption is reasonable. In these kinds of problems, the critters always answer Yes or No, rather than “7” or “broccoli” or “none of your business”, so I assumed that these trolls always answer Yes or No. In order to do that, they’d have to know the real answer, and in order for this to be fair, all questions (as long as they don’t defy logic) should be equally answerable, and so the trolls would have to be omniscient. Furthermore, however, to answer my first question, realize that a troll doesn’t have to know what the others would say or even what he himself would say, since any troll and any arrangement of trolls would give you the same result. All he’d have to know is what’s in the OP. To answer your question (which is the most elegant so far, I might add) the troll would have to be able to think logically, and that’s not stipulated in the OP either.

I think I’d just draw my sword and start rolling dice.