10
$\begingroup$

Seven treasure chests, made of gold, silver, tin, steel, brass, pewter and lead, each contain coins of one of the seven metals. No two chests contain the same type of coin.

  • The pewter chest does not contain tin coins.
  • The brass chest does not contain silver coins.
  • The tin chest does not contain lead coins.
  • The coins in the silver chest and the chest containing the steel coins are of the same metal.
  • The coins in the gold chest and the chest containing the brass coins are of the same metal.
  • The coins in the steel chest and the chest containing the gold coins are of the same metal.

Which chest contains which coins?

$\endgroup$
0

3 Answers 3

9
$\begingroup$

In addition to the other answers, here is how the solutions can be derived using a graph representation.

Let A → B denote "the chest of metal A contains coins of metal B". Then we are looking to put seven arcs in a graph with seven nodes (one of each type of metal) such that each node has both an incoming and an outgoing arc.

From the last three clues, we have the following path:

silver → X → steel → Y → gold → Z → brass

At first glance, it would seem that all seven metals are represented here, in a single cycle linking all chests. But this is forbidden, since we know that the brass chest does not contain silver coins.

Thus we have to reuse metals, and the only way to resolve this is by setting:

X = brass and Z = silver

winding up with the five-metal cycle

silver → brass → steel → Y → gold → silver

Other attempts at instantiating variables will lead to coins of the same metal appearing in more than one chest (i.e. a node with more than one incoming arc in the graph representation).

This leaves the variable Y with three candidate metals: pewter, lead and tin. Here's where the first and third clues come in. If we set Y=tin, then there are two solutions:

the pewter chest can contain either pewter or lead coins, and the lead chest takes the remaining metal type.

Setting either Y=pewter or Y=lead we wind up with a single solution in each case:

the remaining two chests contain only coins of their own type.

Hence, we come to the four solutions given in the other answers.

$\endgroup$
3
  • $\begingroup$ silver → X → steel → Y → gold → Z → brass. You are claiming that X is brass and Z is silver. It is easy to see that X cannot be silver or steel and Z cannot be gold or brass . But, I am unable to figure out further. Request you to please explain how you found the values of X and Z . $\endgroup$ Commented May 4, 2022 at 18:34
  • 1
    $\begingroup$ @HemantAgarwal For example, setting X=gold gives Y=brass, and then both the silver and the brass chests would contain gold coins. Setting either Z=steel or Y=silver means again that X=gold and we have the same problem. Y=brass implies Z=steel with yet again the same result. $\endgroup$
    – Oliphaunt
    Commented May 4, 2022 at 20:25
  • 1
    $\begingroup$ @HemantAgarwal just pen and paper. As I wrote, at least one metal has to be reused in the cycle and then the only solution is for silver to contain brass. Just try it for yourself, come back to the problem a couple of days later if you get stuck. Also, perhaps this depiction in a graph just doesn't work for you? $\endgroup$
    – Oliphaunt
    Commented May 4, 2022 at 20:49
8
$\begingroup$

In addition to Ivo's answer, there are three other configurations that satisfy the problem as currently written:

--------------------
gold --> silver
steel --> tin
lead --> lead
brass --> steel
silver --> brass
tin --> gold
pewter --> pewter
--------------------
gold --> silver
steel --> lead
lead --> gold
brass --> steel
silver --> brass
tin --> tin
pewter --> pewter
--------------------
gold --> silver
steel --> pewter
lead --> lead
brass --> steel
silver --> brass
tin --> tin
pewter --> gold
--------------------

I suspect there was one rule omitted: chests cannot contain coins made of their own metal.

$\endgroup$
4
$\begingroup$

Pewter lead.
Lead pewter.
Gold silver.
Silver brass.
Steel tin.
Tin gold.
Brass steel.

I made a table and removed all none possible matches. Then I started to guess. By luck I didn't reach any unsolvable states and got it at the first time guessing.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.