# Web Puzzles

## A Farmer's Good Fortune

A farmer from a small community is out of money. After a mysterious desease spread among and killed his lifestock, he now needs to quickly make up for the lost animals. He needs a whole grand.
Knowing that the bank won't lend him any money, he pays a visit to the local loan shark. The outlaw, who's known to have a bit of an obsession with puzzles, proposes a deal.

With the \$1,000 he gets, the farmer has to be able to buy a combination of cows, pigs, and sheep, to total exactly 100 heads of lifestock. The combination has to include at least one cow (\$100 each), one pig (\$30 each), and one sheep (\$5 each). The total amount of money spent for the 100 animals has to equal exactly \$1,000.

If the farmer manages to accomplish the task, he'll have to return the money with a "friendly" interest rate. Otherwise, he'll get the normal rate, and the threat of a broken pinkie...

How many of each kind of livestock did the farmer buy?

### A Farmer's Good Fortune Puzzle Solution

Here's one combination:

``` 94 sheep =  \$470
1 pig   =   \$30
5 cows  =  \$500
-----------------
```

Are there anymore?

## A Special Old Guy

Alvin and Buzz are nerds and like doing nerdy things. So Alvin called Buzz one day...

"Buzz, I've finished tracing my family tree back from the year 500 AD, and I found one quite special guy".

"Well, he was x years old in the year x^2 (x squared) and he had a son who was y years old in the year y^3 (y cubed)".

Buzz looked perplexed "Sorry Alvin, but I can't solve for x or y".

"Well, he was your age when his son was born." said Alvin.

"You're right" said Buzz "He was a special old guy! But I still can't solve for x or y".

How old was the old guy when his son was born?

Notes:
Assume that the nerds have the conversation this year, ie 2004 AD.

### A Special Old Guy Puzzle Solution

Firstly, we can say that the date of birth (DOB) for the special old guy (SOG) is:
Equation {a}:
DOB(SOG) = x^2 – x

Similarly, for the son of the special old guy (or SOSOG for short):

Equation {b}:
DOB(SOSOG) = y^3 – y

SOG's age when SOSOG was born was:
Equation {c}:
Age(SOG) = DOB(SOSOG) – DOB(SOG) = (y^3 – y) – (x^2 – x)

There are unlimited solutions to equation {c} so we need some assumptions and limits.

We know that SOG must have been between, say 10 years old and 100 years old when SOSOG was born:

Equation {d}:
10 < Age(SOG) < 100

We also know that both SOG and SOSOG were born some time since the year 500 AD:
Equation {e}:
500 < DOB(SOSOG) < 2004.

Based on equation {b} and {e} we can clearly see that there are only 5 solutions for y. They are y = 8, 9, 10, 11 or 12. Any other solutions for y are in breach of equation {e}.
For each of these possible solutions for y there is only a limited number of solutions for x that comply with {d}. They are:
``` x     y
--------
21     8
22     8
26     9
27     9
31    10
36    11
41    12
```

Any other solutions for x and y are in breach of equation {d}.
SOG's age when his son was born can be calculated for each of these possible solutions by using equation {c} as follows:
``` x      y     Age(SOG)
----------------------
21      8           84
22      8           42
26      9           70
27      9           18
31     10           60
36     11           60
41     12           76
```

So there are 7 different solutions, which is why Buzz said he couldn't solve for x and y.
Now comes the lateral part of the puzzle: Alvin informs Buzz that "...he was your age when his son was born". Of course, Buzz knows his own age. He should therefore be able to pick the correct solution from the list of 7 possible solutions shown above. However, he can't. That means that Buzz (and the special old guy) must be 60 because there are multiple solutions for an age of 60, whereas any other age would yield a unique solution. Any other age and Buzz would be able to solve.
A 60 year old father – quite a special old guy.

## Switching Logic

You are in a basement. In front of you are three light switches, all in their OFF state. These switches are connected to three lightbulbs that are on a wall in the attic, so there's no chance you can see them unless you climb the stairs all the way up. There is a 1-to-1 mapping between the switches and the bulbs.

You are given plenty of time to play around with the switches in the basement, where you can put each individual switch in either its ON or OFF state.

However, you can only go upstairs once to check on the state of the bulbs!

Once you've gone upstairs and checked on the bulbs, you must be able to tell with 100% certainty which bulb is connected to which switch, without having to go down again.

How can you tell which switch is connected to each bulb?

Notes:
• You can't put a switch halfway between ON and OFF, hoping that this would make the bulb flicker like a bad neon light...
• You can't control the switches from a distance, eg with a string or whatever other form of remote control.
• You can't have anyone cooperating with you on the other floor, and that includes your dog who knows how to bark once for a 'yes' and twice for a 'no'.

### Switching Logic Puzzle Solution

Turn switch #1 ON. After about five minutes or so, turn switch #1 OFF and turn switch #2 ON.
Then go upstairs and check on the bulbs.

The one ON is obviously #2. The other ones are OFF, but one of them should be very hot by having been ON for five minutes. That's #1, and the remaining bulb is #3.

## Boxes, Beads, and a Blindfold

You have been named as a traitor by the King, the punishment for this crime is death. Although he is a cruel tyrant he gives you one last chance at freedom. When you are finally brought before him he has this to say to you:

"There are 100 beads, 50 black and 50 white. You will be allowed to draw one bead, whilst blindfolded of course. If it is black you will be condemned to death, if it is white you will be set free".

So far so good you think to yourself, at least I have a 50/50 chance.

"The beads will be distributed amongst four boxes by me," he continued. "You must select a box by opening it, draw one bead from it and then present the bead to the court. Thus will your fate be decided".

Upon saying this a cruel smile appears on the King's face and you suddenly break into a cold sweat as you remember that the King is both very wicked and devilishly cunning.

Assuming that the King is incredibly smart, evil, thinks that you are a stupid, uneducated peasant and wants to minimise your chance of freedom, what strategy should you employ, and what is the probability of surviving?

Notes:
• The King whilst evil won't cheat.
• The trick is to work out how he plans on distributing the beads to minimise your chance of success.
• As soon as you stick your hand in one of the boxes you must draw a bead from it.
• The boxes and beads light and portable, however you are not allowed to remove them from the area.
• The King thinks you are stupid.

### Boxes, Beads, and a Blindfold Puzzle Solution

The king puts 1 black bead in 3 of the 4 boxes and all the other beads (both black and white) in the fourth box.

In the kings' view, you will just randomly pick a box because you are so stupid. This gives you barely 1 chance out of 8 to pick a white bead (1/4 to pick that one box containing white beads multiplied with almost 1/2 to pick a white bead out that box).

Assuming each of the four boxes are identical, by picking up each box in turn, you will be able to tell by weight or the rattling noises which one of the boxes contains the mixed beads. Picking the box with the mixed beads will mean that you have a slightly better than 50% chance of living.

Thanks to "Ben Leil" and "Kobold" for posting solutions in the forum

## Which Chest Is Which

One day Arthur came to Merlin and asked him, "Show me how to be a wise and good king." Merlin replied, "If you can pass a series of mental tests, I will teach you".

Merlin then showed Arthur three chests, one was labelled GOLD COINS, the second was labelled SILVER COINS, and the last, GOLD OR SILVER COINS. He stated that all the three labels were all on the wrong chests. Given that one chest contained gold, one silver, and one bronze.

How many chests must Arthur open to deduce which label goes on which chest?

### Which Chest Is Which Puzzle Solution

Arthur does not need to open any chests.

Since all labels are on the wrong chests, the chest labelled GOLD OR SILVER COINS cannot contain either gold nor silver, so must contain bronze. Thus the chest labelled GOLD COINS must contain silver coins, and SILVER COINS must contain gold.

## U2 Gig

Bono, The Edge, Adam, and Larry must cross a narrow darkened bridge in order to reach the stage where they are due to play in 17 minutes.

Unfortunately they only have one torch between them which must be used to cross the bridge safely and may not be thrown, only carried across the bridge.

The bridge will hold up to two band members at any time.

Each member crosses at their own pace and two members must go at the slower members pace.

Bono can cross in one minute, The Edge in two, Adam in five, and Larry in ten.

How do they make it in time?

### U2 Gig Puzzle Solution

The trick is to get the two slowest people to cross at the same time. One solution is...
• Bono and Edge cross the bridge for which they take 2 mins (Total time = 2)
• Then Bono comes back with the torch (Total Time = 2 + 1 = 3)
• Then Adam and Larry cross the bridge (Total time = 3 + 10 = 13)
• Then Edge comes back (Total = 13+2 = 15)
• Then both Bono and Edge cross the bridge (Time = 15+2=17)

## Duck Hunt

Tim and Tom were playing their Dad's old favourite game machine - a classic Nintendo Entertainment System (NES). The game was, surprisingly, Duck Hunt. Tom was at the controls, shooting innocent ducks with the lightgun.

Tim pokes Tom, and whines, "let me play." Tom looks back, and Mum is looking at them, so Tom begins to feel generous.

"Tell ya what, Tim. If you can answer a riddle about ducks, you can play. Otherwise, I get a half an hour more."

Tim, who occasionally can be a dunce, happily says "OK!".

Tom asks his question, "How many ducks do you have if you have two ducks in front of two ducks, two ducks behind two ducks, and two ducks between two ducks?"

Tim is stumped. "15?"

"Nope," says Tom.

"12?"

"Nope."

Exasperated, Tim says, "Ok, what is the answer?"

When Tom tells him, Mom goes off smiling, Tim stomps off, and Tom gets the high score on the game.

What it the least number of ducks to meet the conditions?

### Duck Hunt Puzzle Solution

Four ducks in a single row would do it.