## Brain-Teaser 505

**From The Sunday Times, 14th February 1971** [link]

Colourland is inhabited by three races, all similar in appearance — Redmen, a truthful people; Greenmen, who always lie; and Bluemen, who sometimes tell the truth and sometimes lie. Their houses are painted either red, green or blue, but no one lives in a house with the colour of his race name.

One day, after a football match, three of the winning team, which won 1-0, were standing together. Their shirts were numbered 1, 2 and 3, and by tradition these three would be one from each race, each occupying a different coloured house.

I asked number 1 if number 2 told the truth more often than number 3, to which he answered “No”. I then asked number 2 if any of the three of them had scored the winning goal, his reply being “I did”.

I next asked one of them if he lived in a certain coloured house, and from his reply I was in fact able to determine:

(i) the colour of each tribesman’s house, and:

(ii) which (if any) scored the goal.Can you?

[teaser505]

## Jim Randell 8:27 am

on15 October 2019 Permalink |The tribes on the island are described as “similar in appearance”, which I take to mean that the setter is not able to determine which tribe the person he is questioning is from, other than from the answers to the questions.

This Python program runs in 84ms.

Run:[ @repl.it ]Solution:Yes. (i) Redman in blue house. Blueman in green house. Greenman in red house; (ii) Redman scored the goal.The third question is asked of player 2, and is: “Is your house green?”.

An answer of “No” allows the questioner to infer:

Similarly, if the third question asked (still of player 2) is: “Is your house red?”, and the answer received is “Yes”, then we can infer:

But we cannot determine who the goal scorer is, only that it isn’t player 2.

If we consider the first question.

If the person we ask is Blue, then they could answer anything. So the following are possible:

If the person asked the first question is Red, then #2 does not tell the truth more often than #3:

If the person asked the first question is Green, then #2 does tell the truth more often than #3:

So there are four possible assignments of players to tribes, and #2 is not Blue, so we can ask them a question, and know we are not going to get a “random” answer.

If we ask #2 “Do you live in a green house?”. We know if G is asked this they must answer “Yes” (as they don’t), so if we get an answer of “No” we know that #2 must be R, and they do not live in a green house.

In this situation the houses are: RB, BG, GR, and we also know that R is #2, and so answered Q2 truthfully, so R scored the goal.

LikeLike