Skip to the page
Puzzles, Charts & Dilemmas

Puzzles

River Crossing Puzzle: Under Its Rules, Two Shortest Routes

Published · Puzzles, Charts & Dilemmas

Folded answers print open where the browser allows it; if one prints closed, open it at https://puzzleschartsanddilemmas.com/puzzles/river-crossing-puzzle/ first.

Where it lands

The wolf, goat and cabbage puzzle asks how a farmer whose boat holds him and one passenger can get all three across a river, when the wolf eats the goat and the goat eats the cabbage whenever he leaves them alone together. Under those rules it can be done: we checked all 16 ways to spread the four over two banks, found 10 of them safe, and found exactly two shortest solutions, both worked out in the fold below the puzzle.

Sections on this sheet (4)
  1. The puzzle
  2. Ten safe arrangements out of sixteen
  3. Where the puzzle comes from
  4. Same rules, bigger boats

A Latin problem collection attributed to Alcuin sets a man beside a river with a wolf, a goat and cabbage. The Latin tells him to bring everything across “illaesa,” unharmed, but it never says who would harm whom, or when. Those rules have to be written down before anyone can count crossings. Here is the puzzle in standard form with our version of the missing rule, so you can try it before you open the answer.

In standard form: (our wording of problem XVIII of the Propositiones ad acuendos iuvenes)

  1. Premise 1:The farmer, the wolf, the goat and the cabbage start on the left bank.
  2. Premise 2:Only the farmer rows; he carries at most one of the three per crossing.
  3. Premise 3:On a bank without the farmer, the wolf eats the goat and the goat eats the cabbage.
  4. Premise 4:Nothing else counts as a loss; any number of crossings is allowed.
  5. Question:What is the fewest crossings that gets all four to the right bank, and in what order?
Puzzle: a river between two banks. Farmer, wolf, goat and cabbage start on the left bank; the boat holds the farmer plus at most one, and only he rows. Without the farmer, wolf eats goat and goat eats cabbage. Goal: all four on the right bank.

Wide figure: scroll it sideways, or open it full size.

The puzzle at the start: all four on the left bank, the boat at the shore, the right bank empty.

Diagram: Puzzles, Charts & Dilemmas, CC BY 4.0

Copy the full credit line

"The wolf, goat and cabbage puzzle at the start" by Puzzles, Charts & Dilemmas, https://puzzleschartsanddilemmas.com/puzzles/river-crossing-puzzle/, licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/).

The puzzle

The farmer stands on the left bank with a wolf, a goat and a cabbage. The only boat is small: it holds him and one passenger, and nobody else can row it. The table sets out the four rules and what each one allows.

RuleWhat it means
P1 StartFarmer, wolf, goat and cabbage are all on the left bank
P2 BoatOnly the farmer rows; each crossing carries him alone, or him and one passenger
P3 LossesA bank without the farmer loses the goat if the wolf is there, and the cabbage if the goat is there
P4 Nothing elseThe wolf ignores the cabbage, the boat never sinks, and there is no limit on crossings

“Shortest” in this page's title means fewest crossings, and one trip from one bank to the other counts as one crossing. Paper slips marked F, W, G and C on a sheet with a river drawn across it are enough to try it. Write down who stands on each bank after every crossing before you open the answer.

The decoy answer

It can't be done. Every plan that only carries things forward strands a pair, either on the first crossing or on the empty trip back after the third, so the puzzle looks impossible. The answer is tempting because it treats every crossing as progress toward the far bank.

Show the checked solution

Checked solution

∴ Under these four rules, the fewest crossings is 7, and exactly two orders reach it. They are mirror images: swap the wolf and the cabbage in one and you get the other.

We checked all 16 bank arrangements. A breadth-first search, which tries every legal crossing from every arrangement it reaches, started on the left bank and found the goal after 7 crossings by exactly two routes. A second method, written separately, counted every sequence of legal crossings one length at a time, and the first length to reach the goal was again 7, with again two sequences.

CrossingDirectionRoute 1: the farmer carriesRoute 2: the farmer carries
1acrossgoatgoat
2backnothingnothing
3acrosscabbagewolf
4backgoatgoat
5acrosswolfcabbage
6backnothingnothing
7acrossgoatgoat

Crossing 4 is the move the decoy never considers: the farmer carries the goat back to the left bank. Without it, the third crossing leaves the goat with the wolf or with the cabbage as soon as he rows away. In knot terms, this one loosens only when you pull a strand back toward you first.

Two lists. Crossing 1: taking nothing, the wolf or the cabbage leaves a pair that eats; only taking the goat is safe. Crossing 3, with nothing ever carried back: taking the wolf or the cabbage leaves it with the goat once the farmer rows back.

Wide figure: scroll it sideways, or open it full size.

What each first crossing leaves behind, and why the third crossing fails if nothing ever comes back.

Diagram: Puzzles, Charts & Dilemmas, CC BY 4.0

Copy the full credit line

"What each first crossing leaves behind" by Puzzles, Charts & Dilemmas, https://puzzleschartsanddilemmas.com/puzzles/river-crossing-puzzle/, licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/).

The search also shows how little choice the puzzle leaves. The 10 safe arrangements are joined by only 10 legal crossings. On the way to the goal there is exactly one fork: after crossing 2, with the farmer back beside the wolf and the cabbage, he can carry either one.

The two branches meet again after crossing 5, closing a loop. From there he can also row back down the other branch, but that only takes him around the loop.

Graph of the 10 safe arrangements, left bank | right bank, in order of crossings from 0 to 7. A single line splits after crossing 2 into two branches, wolf first or cabbage first, and joins again after crossing 5.

Wide figure: scroll it sideways, or open it full size.

The 10 safe arrangements and every legal crossing between them; the two routes split after crossing 2 and meet again after crossing 5.

Diagram: Puzzles, Charts & Dilemmas, CC BY 4.0

Copy the full credit line

"The 10 safe arrangements and the crossings between them" by Puzzles, Charts & Dilemmas, https://puzzleschartsanddilemmas.com/puzzles/river-crossing-puzzle/, licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/).

The solution printed under problem XVIII in Migne's edition follows route 2, carrying the wolf on the third crossing, and it does not mention route 1.

Ten safe arrangements out of sixteen

Each of the four can stand on either bank, so there are 2 × 2 × 2 × 2 = 16 arrangements. Six of them lose something. In four, the wolf is left with the goat, and in two of those the cabbage is there as well; in the other two, the goat is left with the cabbage.

Grid of 16 boxes, one per arrangement, each split into left bank and right bank. Ten are marked safe; six are marked with what is eaten and where. The same 16 rows are in the table below.

Wide figure: scroll it sideways, or open it full size.

All 16 ways to place the four on two banks: 10 safe, 6 where something is eaten.

Diagram: Puzzles, Charts & Dilemmas, CC BY 4.0

Copy the full credit line

"The 16 bank arrangements, 10 safe" by Puzzles, Charts & Dilemmas, https://puzzleschartsanddilemmas.com/puzzles/river-crossing-puzzle/, licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/).

#Left bankRight bankResult
1farmer, wolf, goat, cabbagenobodysafe
2wolf, goat, cabbagefarmerwolf eats goat
3farmer, goat, cabbagewolfsafe
4farmer, wolf, cabbagegoatsafe
5farmer, wolf, goatcabbagesafe
6goat, cabbagefarmer, wolfgoat eats cabbage
7wolf, cabbagefarmer, goatsafe
8farmer, cabbagewolf, goatwolf eats goat
9wolf, goatfarmer, cabbagewolf eats goat
10farmer, goatwolf, cabbagesafe
11farmer, wolfgoat, cabbagegoat eats cabbage
12cabbagefarmer, wolf, goatsafe
13goatfarmer, wolf, cabbagesafe
14wolffarmer, goat, cabbagesafe
15farmerwolf, goat, cabbagewolf eats goat
16nobodyfarmer, wolf, goat, cabbagesafe

All 10 safe arrangements can be reached from the start, and each one lies on at least one of the two shortest routes. A solver who keeps to safe arrangements has no dead end to wander into.

Searching a crossing puzzle by hand

The search behind these numbers needs no computer for a puzzle this small. It works the same way for any crossing puzzle whose rules fit on a card:

  1. Write each arrangement as two lists, left bank | right bank, with the boat on the farmer's side.
  2. Cross out every arrangement the rules forbid. Here that leaves 10 of the 16.
  3. Start a list headed 0 that holds only the starting arrangement.
  4. For each arrangement on the newest list, write down every legal crossing from it. Any arrangement that has not appeared on an earlier list goes on the next one.
  5. Stop at the first list that contains the goal; its number is the fewest crossings.

To count the shortest solutions too, write a number beside each arrangement. The start gets 1, and every other arrangement gets the sum of the numbers of the arrangements on the list before that can reach it in one crossing. The number beside the goal is the count of shortest solutions.

Paper gets unwieldy fast once more travellers join: with six of them and a boat that can be on either side, the lists start from 2⁷ = 128 arrangements before any are crossed out, so the related puzzles below get the same search, run in full rather than on paper.

Where the puzzle comes from

The earliest text we read is problem XVIII of the Propositiones ad acuendos iuvenes, problems to sharpen the young. It is printed in volume 101 of J.-P. Migne's Patrologia Latina, columns 1149–1150, under the running head “Opp. dubia.” The edition files the whole collection among works of doubtful attribution, which is why this page says the collection is attributed to Alcuin and not that he wrote it.

The Latin title is “Propositio de homine et capra et lupo,” the problem of the man, the goat and the wolf. A man must take a wolf, a goat and “fasciculum cauli,” a bundle of cabbage, across a river in a boat that can carry “duos tantum ex ipsis,” only two of them. He has been ordered to bring everything over unharmed.

The Latin leaves out the rule that makes the puzzle work. It never says that the wolf eats the goat or that the goat eats the cabbage, or that either happens only when the man is away. Our P3 writes that rule down. The Latin also leaves open whether “two of them” includes the man, though the solution printed with it treats him as one of the two.

Painted manuscript page. On the left, a younger tonsured monk and an older bearded man labelled Albinus stand together, holding a book; on the right, a seated bishop labelled Otgarius raises his hand. Latin name labels above each figure.

Three figures named in the inscriptions, Rabanus, Albinus (Alcuin) and Otgar of Mainz, in a Fulda manuscript of the second quarter of the 9th century (Vienna, ÖNB, Cod. 652, fol. 2v).

“Rabanus, Albinus and Otgar, Vienna, ÖNB, Cod. 652, fol. 2v” by unknown artist (Fulda manuscript), Public domain

Full credit line

"Rabanus, Albinus and Otgar, Vienna, ÖNB, Cod. 652, fol. 2v" by unknown artist (Fulda manuscript) — https://commons.wikimedia.org/wiki/File:Raban-Maur_Alcuin_Otgar.jpg — Public domain (manuscript painting made at Fulda in the 2nd quarter of the 9th century by an unnamed artist (PD-old-100 in the US and the EU); faithful reproduction of a two-dimensional work (PD-Art: Bridgeman v. Corel in the US, DSM Directive 2019/790 art. 14 in the EU))

Albinus is the name Migne's edition pairs with Alcuin in its running heads: “Albini seu Alcuini,” of Albinus or Alcuin. The painting has no connection with the puzzle beyond that name. A 1992 article in The Mathematical Gazette by John Hadley and David Singmaster carries the collection's English title, “Problems to Sharpen the Young”; we have seen only its bibliographic record.

Illustration: a man stands on a riverbank beside a small empty rowing boat, with a wolf, a goat and a cabbage waiting near him; the far bank is empty.

The puzzle's starting scene: one boat, one rower and three passengers who cannot all be left together.

Illustration: Puzzles, Charts & Dilemmas. Generated schematic illustration — not a photograph or historical record. Reuse: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/), to the extent Puzzles, Charts & Dilemmas holds rights in it.

Same rules, bigger boats

Problem XVIII sits between two other crossing puzzles. In problem XVII, three brothers each travel with a sister, the boat holds two, and the Latin says each brother desires his neighbor's sister. We read that as a rule: no sister may be with another brother unless her own brother is there too. In problem XIX, a man and a woman each weigh as much as a loaded cart, their two children together weigh the same, and the boat can carry one cartload.

The problem after that, XX, repeats problem XIX with a pair of hedgehogs and their two young, and its printed solution opens “Similiter, ut superius,” in the same way as above.

We wrote each one as rules and searched it the same way. We added a fourth puzzle, the one known as missionaries and cannibals; we have not traced it to a source we read, so its row states our rules only.

Bar chart of fewest crossings under this page's rules: three brothers and three sisters, boat for two, 11; three missionaries and three cannibals, boat for two, 11; a man, a woman and two children, boat for one cartload, 9. Rules in the table below.

Wide figure: scroll it sideways, or open it full size.

Fewest crossings for three related puzzles, under the rules in the table below.

Diagram: Puzzles, Charts & Dilemmas, CC BY 4.0

Copy the full credit line

"Fewest crossings for three related river-crossing puzzles" by Puzzles, Charts & Dilemmas, https://puzzleschartsanddilemmas.com/puzzles/river-crossing-puzzle/, licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/).

PuzzleOur rulesFewest crossingsShortest ordersSource
Three brothers, three sistersBoat holds 2; anyone rows; no sister with another brother, on a bank or in the boat, unless her own brother is there11486Problem XVII, col. 1149
Missionaries and cannibals, three of eachBoat holds 2; anyone rows; on a bank where any missionary stands, cannibals never outnumber missionaries114Not traced
A man, a woman, two childrenBoat carries at most one cartload: the man, the woman, one child or both children; anyone rows98Problem XIX, col. 1150

The brothers, sisters and children are told apart, so swapping two people counts as a different order. The missionaries and cannibals row counts only how many of each kind cross each time. The solutions printed in the collection use 11 crossings for problem XVII and 9 for problem XIX, the same numbers our search gives as the minimum under our rules. In the printed solution to problem XVII, the speaker first crosses with his own sister, leaves her there and rows back alone; the other two sisters then cross together.

A river crossing can also be a fact to read rather than a puzzle to solve. Minard's map of the French army's losses in Russia, drawn by Charles Minard in 1869, labels the Bérézina river, and the black band, which his legend says stands for the men leaving Russia, crosses it. There the order of events is read from the map, not chosen.

Push back:

The strongest objection is that the two answers are really one. The rules treat the wolf and the cabbage alike, each safe with anything but the goat, so swapping their names turns route 1 into route 2, and the puzzle's real content is one insight that no count of crossings measures. We accept the mirror point, since we count different crossing orders and the fold calls the two mirror images. Whether that one insight is the whole puzzle is a disagreement the numbers cannot settle.

  • Knights and Knaves: Two speakers instead of two banks; once the rules are written down, every case can be checked, including the ones with no answer.
  • Tower of Hanoi: One disk moves at a time there too, and each added disk doubles the count of moves and adds one.

Sources

  1. Propositiones Alcuini doctoris ad acuendos juvenes, problems XVII–XIX with their solutions, in J.-P. Migne (ed.), Patrologiae cursus completus, Series Latina, vol. 101 (Paris: J.-P. Migne), cols. 1149–1150, printed among the works of doubtful attribution (Opera dubia). https://archive.org/details/patrologiaecur101mign Read: columns 1149–1150 in Latin, with the column numbers and the running head checked on the scanned pages.
  2. John Hadley and David Singmaster, “Problems to Sharpen the Young,” The Mathematical Gazette 76, no. 475 (March 1992): 102–126. doi:10.2307/3620384. https://doi.org/10.2307/3620384 Read: bibliographic record only.
  3. Charles Joseph Minard, Carte figurative des pertes successives en hommes de l'Armée Française dans la campagne de Russie 1812–1813, dated on the map “Paris, le 20 Novembre 1869”; printers' lines “Autog. par Regnier, 8. Pas. Ste Marie St Gain à Paris” and “Imp. Lith. Regnier et Dourdet.” As reproduced on Wikimedia Commons, File:Minard.png (scan source not recorded). https://commons.wikimedia.org/wiki/File:Minard.png Read: the map image: the Bérézina label and the legend line on the black band; also the whole map: title, legend, every troop figure and place name, the temperature graph and the scale bar, from the full-size image.

Downloads: Both shortest solutions and the arrangement graph (JSON) (file notes: source, version and license (JSON)) · All 16 bank arrangements (CSV) (file notes: source, version and license (JSON)) · Related crossing puzzles under our rules (CSV) (file notes: source, version and license (JSON))

Cite this page

Puzzles, Charts & Dilemmas. “River Crossing Puzzle: Under Its Rules, Two Shortest Routes.” Puzzles, Charts & Dilemmas. Published 2026-10-31. https://puzzleschartsanddilemmas.com/puzzles/river-crossing-puzzle/. Accessed: add the date you read it.

Dates are given as year-month-day. 31 October 2026 is the latest substantive revision.