rec.puzzles Archive

Three candle boxes are labeled "white", "red", and "white and red." All three labels are incorrect.

logic/wrong.labels Added material

Problem

Three candle boxes are labeled "white", "red", and "white and red."  All
three labels are incorrect.  How many candles do I have to pull out to
correctly label the boxes, and how do I do it?

Also:

There are four boxes, labeled:
  "Pennies and Nickels"
  "Nickels and Dimes"
  "Dimes and Quarters"
  "Just Quarters"

All the labels are incorrect.  How many coins do I have to sample to
correctly label the boxes, and how do I do it?
Show solution
One candle suffices.  Take one candle from the box labeled "white and
red."  Say that it's white.  You know that this must be the white box,
therefore the box labeled "red" must contain mixed and the box labeled
"white" must actually be the red candles.

In the four-box case, the answer is three.

Number the boxes from 1 to 4, so that Box 1 is labeled P&N, Box 2 is
labeled N&D, Box 3 is labeled D&Q, Box 4 is labeled Q

First, request Box 3. If the coin from Box 3 is a dime or quarter,
request Box 2, and whatever comes out, you will have enough information
to know which two boxes to choose. Namely:

If ?NQ?, meaning a nickel (or penny) from Box 2 and a quarter from Box 2,
then choose boxes 1 & 4.
If ?QD? then choose boxes 1 & 2.
In all other cases (?ND?, ?DD?, ?DQ?, ?QQ?) choose boxes 1 & 3.

If the coin from Box 3 is a nickel (or penny), request Box 1 next. If the
coin from Box 1 is also a nickel, choose boxes 1 & 4. If the coin from Box
1 is a dime, request Box 4; if it's a quarter, request Box 2. Then choose
as follows:

If D?NN then choose boxes 1 & 2.
If D?ND then choose boxes 1 & 4.
If D?NQ then choose boxes 1 & 4

If QNN? then choose boxes 1 & 3.
If QDN? then choose boxes 1 & 2.
If QQN? then choose boxes 1 & 2.

Additional material

[ Editor: the four-box solution in this entry is Fred Galvin's
corrected posting.  The puzzle was posed by Wei-Hwa Huang as follows,
and Galvin's posting adds the remarks below. ]

There are four boxes, labeled:
  "Pennies and Nickels"
  "Nickels and Dimes"
  "Dimes and Quarters"
  "Just Quarters"

Now, I'll tell you that all four labels are correct, but all of them
are on the wrong boxes.  You, being a smart puzzle solver (I hope), can
easily verify that this means one can choose two boxes such that those
two boxes have the labels for the other two boxes, and vice versa.

Define a "request" as follows:
  1.  You specify a box.
  2.  I take a coin out of that box, show it to you, and put it back.

At least how many requests, and for which boxes, do you have to make so
that no matter what coins I show you, you can choose two boxes which
have the labels of the other two boxes?

-- Wei-Hwa Huang

The answer is 3.  You can't do it with only 2 requests.  Even to do it
with 3 requests you have to use an adaptive strategy, i.e., you can't
decide on 3 boxes in advance.

. . . pennies will be ignored, i.e., regarded as nickels.

[ Editor: in the solution, "?NQ?, meaning a nickel (or penny) from Box
2 and a quarter from Box 2" should read "... a quarter from Box 3";
the slip is in Galvin's original. ]

-- Fred Galvin <galvin@math.ukans.edu>

The same puzzle with tarantulas and bananas appeared as a Marilyn vos
Savant brainteaser:

In article <CE04A6.I3L@umassd.edu>, Frank Pinto <rolls@cis.umassd.edu> wrote:
>You have three boxes labeled
>1)tarantulas
>2)bananas
>3)tarantulas and bananas
>
>However the labels do not match the contents of the boxes.
>You must rearrange them.
>What is the minimum number of boxes from which you would
>have to remove an item in order to correctly be able to
>label all three?

This is a very old puzzle. I'm surprised that Marilyn digs up such
chestnuts.

You left out an important piece of information: you should explicitly state
that *every* box is labeled incorrectly.

Draw one thing from the box labeled 'Tarantulas and Bananas'. Assume you
draw a banana [there's a symmetrical argument if you draw a tarantula].
Because the box is labeled incorrectly, it can't contain both tarantulas
and bananas, and since you just drew a banana, it can't contain tarantulas,
therefore you can confidently label this box 'Bananas'.

Now, you're left with two boxes, one incorrectly labeled 'Tarantulas' and
one labeled 'Bananas'. You know that one of these boxes should be labeled
'Tarantulas and Bananas' and the other 'Tarantulas'. If the one that's
currently labeled 'Bananas' were to be relabeled 'Tarantulas and Bananas',
that would leave the label 'Tarantulas' to go on the box that's currently
labeled 'Tarantulas'... contradicting the premise that all boxes are
incorrectly labeled. Therefore, you can relabel the box labeled 'Bananas'
as 'Tarantulas', and 'Tarantulas' as 'Bananas and Tarantulas'.

-- Jonathan Haas <positron@quip.eecs.umich.edu>