Skip to content

River Crossing Puzzles with Answers (and How to Solve Them)

River crossing puzzles with answers: the wolf, goat and cabbage puzzle plus 3 harder ones, and a simple method that works on them step by step.

A puzzled farmer scratches his head beside a wolf, a goat and a cabbage, with a thought bubble ruling out unsafe pairs

Many river crossing puzzles come down to one trick: list which pairs can’t be left alone, then never leave one alone. The best-known one, the wolf, goat and cabbage puzzle, takes 7 crossings, and the first move is always the goat. Below are four river crossing puzzles, three with answers hidden until you click, and a method that works on any of them. The puzzle is old, too: its first known home is a book of brain teasers from around 800.

The rules every river crossing puzzle shares

You have a river, a boat and a group of things to move across. Many river crossing puzzles share the same few rules:

  • The boat holds a limited load, and someone has to row it.
  • Some pairs are unsafe together. Leave them alone and something goes wrong.
  • Everything on a bank counts while the boat is away, on both sides of the river.
  • You win when everyone is on the far bank, with nobody lost on the way.

The classic dates back to at least the 9th century. In the wolf, goat and cabbage puzzle, a farmer has to ferry all three across in a boat that holds only the farmer and one of them. The wolf and the goat can’t be left alone together, and neither can the goat and the cabbage.

Its earliest known version is Proposition XVIII in Propositiones ad Acuendos Juvenes, a collection of puzzles attributed to Alcuin of York, who died in 804. That’s the safe way to say it: Alcuin’s authorship is a matter of conjecture, and the oldest known copy dates from the late 9th century. His solution used 7 crossings, the same count you’ll find below. Some versions swap in a fox, a goose and a bag of beans, but the logic doesn’t change.

How to solve a river crossing puzzle: list the unsafe pairs

Start by writing down every unsafe pair, because in puzzles like the farmer’s those pairs are the whole puzzle. Then follow five habits:

  1. List the unsafe pairs. For the farmer, that’s wolf and goat, and goat and cabbage. Wolf and cabbage are fine together.
  2. Make the first move one that leaves a safe bank. Ask who you can take so that what stays behind has no unsafe pair.
  3. Bring something back. This is the trick that breaks the stuck point. It feels like going backwards, but in the farmer puzzle it’s the only way forward.
  4. Don’t undo the move you just made. Carrying the same item straight back puts you where you were two crossings ago.
  5. Draw the two banks. Write each state as left side / right side, and check both sides after every crossing.

You can also draw the whole puzzle as a map. Each arrangement of who’s on which bank is a point, and each boat trip is a line between two points. Cross out the unsafe arrangements, and any path from the start to the finish is a solution. CSIRO’s Double Helix describes it with circles for positions and lines for trips. For the farmer puzzle, the 8 ways to place the wolf, goat and cabbage on the two banks are the corners of a cube, and the 12 possible moves are its edges. Cross out the unsafe ones and only the two solutions are left.

That “state graph” idea is a standard example in early AI: the computer scientist Saul Amarel used the missionaries and cannibals puzzle in 1968 to show how to represent a problem. You don’t need a computer for the small ones. A pencil and the left / right notation will do.

It’s the same kind of reasoning as knights and knaves puzzles: write down what’s allowed, rule out what breaks, and see what’s left.

Puzzle 1: the wolf, goat and cabbage

A farmer must take a wolf, a goat and a cabbage across a river. The boat holds the farmer and one of them. If the wolf and the goat are left alone, or the goat and the cabbage, one eats the other. How does the farmer get all three across?

Show the answer

7 crossings, and the goat goes first.

  1. The farmer takes the goat across. The wolf and cabbage stay behind, and they’re safe together.
  2. The farmer rows back alone.
  3. The farmer takes the wolf across.
  4. The farmer brings the goat back. This is the move that feels wrong, and it’s the one that makes the puzzle work.
  5. The farmer takes the cabbage across. The goat waits alone on the left.
  6. The farmer rows back alone.
  7. The farmer takes the goat across.

After each crossing, the banks look like this:

Step Left bank Right bank
Start wolf, goat, cabbage, farmer nothing
1. Goat over wolf, cabbage farmer, goat
2. Farmer back wolf, cabbage, farmer goat
3. Wolf over cabbage farmer, wolf, goat
4. Goat back goat, cabbage, farmer wolf
5. Cabbage over goat farmer, wolf, cabbage
6. Farmer back goat, farmer wolf, cabbage
7. Goat over nothing all four

Why the goat first? It’s the only one that sits in two unsafe pairs. Carry the wolf over first and the goat is left with the cabbage. Start with the cabbage and the goat is left with the wolf. Only taking the goat leaves a safe bank.

Notice that the wolf and the cabbage swap places in the middle, with the goat riding back to cover the gap. You can also take the cabbage over in step 3 and the wolf in step 5. Wikipedia notes the puzzle has exactly two shortest solutions, and they differ only in that order.

Puzzle 2: three missionaries and three cannibals

Three missionaries and three cannibals stand on one bank. The boat holds two, and one of them has to row. On any bank that has missionaries on it, the cannibals may never outnumber the missionaries. How do all six cross?

Show the answer

11 crossings. In the Wikipedia article, 11 is the shortest answer, and it’s one of four shortest solutions. Here’s one, with M for missionaries and C for cannibals:

Crossing Who rows Left bank Right bank
Start 3M 3C nothing
1 2 cannibals over 3M 1C 2C
2 1 cannibal back 3M 2C 1C
3 2 cannibals over 3M 3C
4 1 cannibal back 3M 1C 2C
5 2 missionaries over 1M 1C 2M 2C
6 1 missionary and 1 cannibal back 2M 2C 1M 1C
7 2 missionaries over 2C 3M 1C
8 1 cannibal back 3C 3M
9 2 cannibals over 1C 3M 2C
10 1 cannibal back 2C 3M 1C
11 2 cannibals over nothing 3M 3C

Crossing 6 is the surprise: a missionary and a cannibal come back together, so neither bank gets outnumbered.

A close relative is the jealous husbands puzzle. In that version, three married couples have to cross, and no wife may be with another man unless her husband is there too. Pressman and Singmaster show 3 couples can cross in 11 one-way crossings. Alcuin’s book has the jealous husbands puzzle too (Problem 17, three men each with a sister). The missionaries and cannibals form is much younger: it only appeared at the end of the 19th century.

Puzzle 3: four people, one torch

Here the limit isn’t safety but time. Four friends have to cross a narrow bridge at night with one torch. At most two can cross at once, and anyone crossing needs the torch. They take 1, 2, 5 and 10 minutes to cross, and a pair walks at the slower one’s pace. What’s the shortest time to get everyone across?

The answer, 17 minutes, is hidden in the bridge at night brain teaser. The shape is the same as the farmer’s: someone has to carry the torch back, and who that is decides everything.

Puzzle 4: a boat that holds one soldier or two children

A group of soldiers comes to a river. The only boat is a small one that holds either one soldier or two children, and two children are with it. Every soldier must get across, and the two children are left with their boat. How? Try it with two soldiers first.

Show the answer

8 crossings for 2 soldiers. The count below comes from working through every possible move.

  1. Both children cross.
  2. One child rows back.
  3. Soldier 1 crosses alone.
  4. The other child rows back.
  5. Both children cross.
  6. One child rows back.
  7. Soldier 2 crosses alone.
  8. The other child rows back.

Now the soldiers are across, and the children and the boat are back where they started. If you’d rather have the children finish on the far bank with the soldiers, add one more crossing.

Steps 1 to 4 are a loop: they move one soldier across and put everything else back where it began. Each soldier costs 4 crossings, so 1 soldier takes 4, 2 take 8, and n soldiers take 4n. That’s the fewest possible, and a search of every move found no shorter answer. This puzzle shows a pattern, not a trick. Like the Tower of Hanoi, one repeating idea solves any size.

It’s close to Alcuin’s Problem 19: a man, a woman and two children cross in a boat that carries one adult’s weight. Here the limit is weight, not who’s left with whom.

Why some river crossing puzzles can’t be solved

A river crossing puzzle has no answer when the boat is too small for its crowd. Four couples in a two-person boat is the classic case: no wife may be with another man unless her husband is there, and 4 couples can’t cross. Wikipedia’s article gives the pattern for the jealous husbands form: with a two-person boat, 2 and 3 couples can cross, and 4 or more can’t. A three-person boat handles up to 5 couples, but not 6 or more. With a four-person boat, any number of couples can cross.

Four missionaries and four cannibals with a two-seat boat is the same story. Working through every move shows there’s no answer, and a three-seat boat does it in 9 crossings.

The history is a nice detail. Tartaglia gave a sketchy solution for 4 couples, and Bachet showed it was wrong and argued that 4 couples can’t cross. In 1879, De Fontenay showed 4 or more couples can cross if the river has an island, according to Pressman and Singmaster.

How do you spot an unsolvable one? Try the first few moves on paper. If every route you try runs into a trip that leaves one bank unsafe, check whether the boat is too small. In the state graph, that means no path leads from the start to the finish. A bigger boat or an island is what breaks the deadlock.

Make your own river crossing puzzle

Build one in four steps:

  1. Pick 3 or 4 items: a fox, a hen, a bag of grain, a dog.
  2. Choose the unsafe pairs, and say how many the boat holds.
  3. Test it by working through the banks, as in the tables above.
  4. Count the answer, or find out why there isn’t one.

Here’s a quick test: with 3 items, if every pair is unsafe and the boat holds one item, there’s no answer, because the first trip always leaves two items alone. Make one pair safe and you have the wolf, goat and cabbage puzzle, which does have an answer.

Try it on a friend, then trade. For something different, try Loopaway, a free arrow puzzle in your browser where the order of your taps matters. If you’d like a longer logic puzzle, read how to solve zebra puzzles, or try the lateral thinking puzzles if you like answers hiding in a twist of wording. More quick games are at free puzzle games in your browser.

Frequently asked questions

How do you solve the wolf, goat and cabbage puzzle?

Take the goat across first, go back alone, take the wolf (or the cabbage) across, bring the goat back, take the cabbage (or the wolf) across, go back alone, and take the goat over last. That's 7 crossings.

Which should the farmer take across first?

The goat. It's the only one that can't be left alone with either of the others, and the wolf and cabbage are safe together.

How many crossings does the wolf, goat and cabbage puzzle take?

Seven: four forward and three back. There are exactly two shortest solutions, and they differ only in whether the wolf or the cabbage goes second.

Can a river crossing puzzle be unsolvable?

Yes. Four couples can't cross in a two-person boat if no wife may be with another man unless her husband is there. A bigger boat, or an island in the river, fixes it.

Where does the river crossing puzzle come from?

The earliest known version of the wolf, goat and cabbage puzzle is in Propositiones ad Acuendos Juvenes, a puzzle book attributed to Alcuin of York, who died in 804.

Sources

  1. Wolf, goat and cabbage problem (Wikipedia)
  2. Missionaries and cannibals problem (Wikipedia)
  3. The jealous husbands and The missionaries and cannibals, Pressman and Singmaster, The Mathematical Gazette (Cambridge University Press)
  4. Propositiones ad Acuendos Juvenes (Wikipedia)
  5. Alcuinundrums: Seven brain teasers from the early Middle Ages, Thijs Porck
  6. Alcuin's River Puzzles, Bosbury and District History Resource
  7. River crossings, CSIRO Double Helix
  8. 10 Brain Teasers for a 5-Minute Break (with Answers), EnjoGames
  9. Loopaway: Free Arrow Puzzle Game, Play Online, EnjoGames

Play a free game

←All posts