Some help for John McClane

So in the course of watching the third Die Hard instalment (Die Hard with a Vengeance) last night we ended up having a quick problem solving session when McClean & Zeus (Bruce Willis & Samuel L. Jackson) are presented with a riddle.

The premise is there are two jugs, a 5 gallon jug and a 3 gallon jug, and our protagonists have to fill one of the jugs with exactly 4 gallons. From our calculations there are two ways to do it:

Method 1

  • Fill the 5 gallon jug
  • Empty the 5 gallon jug into the 3 gallon jug leaving 2 gallons
  • Empty the 3 gallon jug
  • Pour the 2 gallons from the 5 into the 3 leaving nothing in the 5 and 2 in the 3
  • Fill the 5 gallon jug
  • From the 5 gallon jug top off the 3 gallon jug leaving 4 gallons exactly in the 5 gallon jug

Method 2

  • Fill the 3 gallon jug and empty into the 5 gallon jug (now 3 is empty and 5 has 3 gallons)
  • Fill the 3 gallon jug again and top off the 5 gallon jug (the 5 gallon is now full, the 3 gallon has 1 gallon in it)
  • Empty the 5 gallon jug
  • Empty the 1 gallon from the 3 gallon jug into 5 gallon jug
  • Fill the 3 gallon jug and empty it into the existing 1 gallon in the 5 gallon jug leaving exactly 4 gallons

Are there any more ways to do it? Oh and if you see Bruce Willis, tell him he’s welcome 😉

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s