The five children Ann, Ben, Con, Den and Ern
are of different ages. Three of them are
honest but the other two always lie.
Ben said to Ern "I am younger than you", and
in fact there are exactly 12 choices of X
and Y such that X could say that to Y.
Ten of the 12 are:
Ben to Ern Con to Ann
Con to Ben Con to Den
Con to Ern Den to Ben
Den to Con Den to Ern
Ern to Ann Ern to Den.
List the five children in increasing order
of age.
Ciao,
Chappy.
The number of claims of being younger must be the multiset
{0,1,2,3,4}. The number of claims being made is precisely
that. Each person who always lies claims 4-x rather than x.
Therefore either the guys claiming 0 and 4 lie, or the
guys claiming 1 and 3 lie. That's either Ann & Con, or Ben
& Den. Den contradicts Ann, Con, and Ern, so he must lie.
So Den's younger than 1, and Ben's younger than 3.
Con < Ben < Ern < Den < Ann
However, that doesn't match Ben's answers, maybe I goofed.
Unless the puzzle's Teabagged, of course. If Ben were to
say it to just Con, rather than Ern, then my answer would
fit.
Phil
--
Dear aunt, let's set so double the killer delete select all.
-- Microsoft voice recognition live demonstration
I don't _think_ it is. I attacked it by brute-force exhaustive
computer search, which told me that out of all the possible 5!
age-orderings of the children and all the possible 10 subsets of
them who are liars, there is exactly one possibility which yields
exactly twelve claims of youngerness including the listed ten, and
that is
Con < Ern < Ben < Den < Ann with Ben and Den the liars.
--
Simon Tatham "What a caterpillar calls the end of the
<ana...@pobox.com> world, a human calls a butterfly."
> Phil Carmody <thefatphi...@yahoo.co.uk> wrote:
>> Con < Ben < Ern < Den < Ann
>>
>> However, that doesn't match Ben's answers, maybe I goofed.
>> Unless the puzzle's Teabagged, of course.
>
> I don't _think_ it is. I attacked it by brute-force exhaustive
> computer search, which told me that out of all the possible 5!
> age-orderings of the children and all the possible 10 subsets of
> them who are liars, there is exactly one possibility which yields
> exactly twelve claims of youngerness including the listed ten, and
> that is
>
> Con < Ern < Ben < Den < Ann with Ben and Den the liars.
But that requires Ern to claim he's < Ben
The question stated:
Ben to Ern Con to Ann
Con to Ben Con to Den
Con to Ern Den to Ben
Den to Con Den to Ern
Ern to Ann Ern to Den.
No Ern < Ben.
Phil Carmody <thefatphi...@yahoo.co.uk> writes:
> Chappy <petergreg...@hotmail.com> writes:
>> Enigma 1480 - Getting older
>> New Scientist magazine, 9 February 2008.
>> By Susan Denham.
>>
>> The five children Ann, Ben, Con, Den and Ern
>> are of different ages. Three of them are
>> honest but the other two always lie.
>>
>> Ben said to Ern "I am younger than you", and
>> in fact there are exactly 12 choices of X
>> and Y such that X could say that to Y.
>> Ten of the 12 are:
>>
>> Ben to Ern Con to Ann
>> Con to Ben Con to Den
>> Con to Ern Den to Ben
>> Den to Con Den to Ern
>> Ern to Ann Ern to Den.
>>
>> List the five children in increasing order
>> of age.
Firstly, a fixed version of my former answer:
> The number of claims of being younger must be the multiset
> {0,1,2,3,4}. ... Each person who always lies claims 4-x
> rather than x.
To get to twelve, the claims must either be {4,1,2,1,4} or
{0,3,2,3,4}.
In the former case, there needs to be another claim by Ann
(to make the 1), and another claim by Den (to make the 2nd 4).
From there, either Ben or Ann must have lied (one ought to
have made 3 claims), and either Den or Con must have lied
(one ought to have made 0 claims).
> Den contradicts Ann, Con, and Ern, so he must lie.
So Ben also lies. So the order would be
C < B < E < A < D
But this contradicts the claims made, (in particular from
liar Ben) so cannot be the case.
So it must be the latter case {0,3,2,3,4}. There therefore
needs to be either another claim from Ben (to reach 2) and
another from Ern (to reach 3), or two more claims from Ben
(to reach 3).
Looking at the latter sub-case, Ern and either Ben or Den
are liars. As before, Den must be a liar, and Ben, and so
this subcase requires no further attention.
So Ben should have made 2 claims, and Ern should have made
3. Ben and either Ern or Den are liars. So it must be Ben
and Den.
So C < E < B < D < A.
Which is better.
Secondly, one can approach it a slightly different way, and
still not need to resort to brute force:
The majority of the above solution comes from recognising in
every case that D must be the liar, and therefore B must be
also. So drawing out a table of corrected claims of being
younger, we get:
<ABCDE
A\
~By\yy
Cyy\yy
~Dy \
Ey y\
Note that by making additional claims, B and D can remove
'y's, and A, C, and E can add 'y's.
The contradictions lie here:
!ABCDE
A\
~B \+ -
C +\
~D \
E - \
So Ern needs to add a y and Ben needs to remove a y.
<ABCDE
A\
~By\ y
Cyy\yy
~Dy \
Eyy y\
C < E < B < D < A
Which was much easier. It even immediately tells you
which claims are missing.
The question stated that there were twelve ordered pairs (P,Q) of
children such that P could claim they were younger than Q, and it
listed _ten_ of those twelve. (Ern,Ben) was one of the two remaining
pairs. For completeness, the other was (Ben,Con).
--
for k in [pow(x,37,0x13AC59F3ECAC3127065A9) for x in [0x195A0BCE1C2F0310B43C,
0x73A0CE584254AB23D5A0, 0x12878657EA814421CC92, 0x7373445BB3DA69996F4A,
0x77A7ED5BC3AA700E80B2, 0xE9C71C94ED87ADCF7367, 0xFE920395F414C1A5DB50]]:
print "".join([chr(32+3*((k>>x)&1))for x in range(79)]) # <ana...@pobox.com>
I think my solution's a little simpler than Phil's.
First, if everyone told the truth, they could make
exactly ten statements "I am younger than you".
For two liars to increase this by two, the liars
must be either the middle and second oldest, or
the oldest and second youngest.
Second, we note that Den and Ern contradict each
other and Con and Den contradict each other. So the
two liars must be either Con and Ern, Ann and Den,
or Ben and Den. We take the three cases and form a
partial order of ages from the ten statements.
1. If Con and Ern lie, then D < B < E < C, A < E,
so the liars are the oldest and second oldest,
which we know is wrong.
2. If Ann and Den lie, then C < B < E < A, E < D,
so again the liars are the oldest and second oldest.
3. If Ben and Den lie, then C < E < B < D, E < A.
The second youngest is Ern, so the liars must be
the middle and second oldest, leaving Ann to be
the oldest: C < E < B < D < A .
Dan