The puzzle
A farmer has to get a wolf, a goat and a cabbage across a river. The boat is small: it carries the farmer and at most one passenger, and only the farmer can row. If the farmer leaves the wolf alone with the goat, the wolf eats the goat. If the farmer leaves the goat alone with the cabbage, the goat eats the cabbage. The wolf has no interest in the cabbage.
It is one of the oldest puzzles we know of: a version appears in a collection of problems attributed to Alcuin of York, written around the year 800.
How to play it here
The farmer is always in the boat. Tap a passenger on the bank where the boat is to put it in the boat, or tap it in the boat to take it out again. Then press Cross. When the boat arrives, the passenger steps off by itself. If a crossing leaves a hungry pair alone on the other bank, the try ends and you see who was eaten. Start over resets the puzzle at any time.
How we calculate your result
When everyone is safely across, you see your time and the number of crossings. The clock runs from the moment you press Start puzzle until the crossing that finishes it, so thinking time before your first move counts. Every trip of the boat is one crossing, including trips the farmer makes alone.
The fewest crossings that can solve the puzzle is 7. We didn't take that from a book: the site works it out by trying every safe sequence of crossings, shortest first, and that search finds exactly 2 solutions of 7 crossings and none shorter.
What does my rating mean?
The rating compares your crossings with the fewest possible, 7, so it needs no averages. Every extra trip lowers it:
| Rating (crossings) | Crossings |
|---|---|
| Perfect | 7 |
| Excellent | 8 |
| Good | 9 |
| Fair | 10–12 |
| Keep trying | 13+ |
Other versions: fox, chicken and corn
The same puzzle is told with different characters: a fox, a chicken and a bag of corn, or a fox, a goose and a bag of beans. The rules and the solution are the same. Whatever stands in for the goat can't be left with either of the others, so it is the one that crosses first and makes one trip back.
A hint
Nothing says the boat has to come back empty. If you're stuck after the first crossing or two, think about what you could bring back.
The solution
Both shortest solutions, in case you want to check yours. Spoilers, obviously.
Solution 1
- Take the goat across.
- Go back alone.
- Take the wolf across.
- Take the goat back.
- Take the cabbage across.
- Go back alone.
- Take the goat across.
Solution 2
- Take the goat across.
- Go back alone.
- Take the cabbage across.
- Take the goat back.
- Take the wolf across.
- Go back alone.
- Take the goat across.
The two solutions are mirror images of each other: they differ only in whether the wolf or the cabbage crosses second. The goat has to go first, and it has to come back once.
Enjoyed planning moves ahead? The Tower of Hanoi is a longer puzzle of the same kind, and Make 24 is a quick one with numbers.