Fox, goose and bag of beans puzzle
The story 
Once upon a time a farmer went to market and purchased a fox, a goose, and a bag of beans. On his way home, the farmer came to the bank of a river and rented a boat. But in crossing the river by boat, the farmer could carry only himself and a single one of his purchases - the fox, the goose, or the bag of the beans.
If left alone, the fox would eat the goose, and the goose would eat the beans.
The farmer's challenge was to carry himself and his purchases to the far bank of the river, leaving each purchase intact. How did he do it?
The first step must be to bring the goose across the river, as any other will result in the goose or the beans being eaten. When the farmer returns to the original side, he has the choice of bringing either the fox or the beans across. If he brings the fox across, he must then return to bring the beans over, resulting in the fox eating the goose. If he brings the beans across, he will need to return to get the fox, resulting in the beans being eaten. Here he has a dilemma, solved by bringing the fox (or the beans) over and bringing the goose back. Now he can bring the beans (or the fox) over, leaving the goose, and finally return to fetch the goose.
His actions in the solution are summarised in the following steps:
- Bring goose over
- Bring fox or beans over
- Bring goose back
- Bring beans or fox over
- Bring goose over
Thus there are seven crossings, four forward and three back.
Occurrence and variations 
The puzzle is one of a number of river crossing puzzles, where the object is to move a set of items across a river subject to various restrictions.
In the earliest known occurrence of this problem, in the medieval manuscript Propositiones ad Acuendos Juvenes, the three objects are a wolf, a goat, and a cabbage. Other cosmetic variations of the puzzle also exist, such as wolf, sheep, and cabbage;;, p. 26 fox, chicken, and grain;, fox, goose and corn and panther, pig, and porridge. The logic of the puzzle, in which there are three objects, A, B, and C, such that neither A and B nor B and C can be left together, remains the same.
The puzzle has been found in the folklore of African-Americans, Cameroon, the Cape Verde Islands, Denmark, Ethiopia, Ghana, Italy, Russia, Romania, Scotland, the Sudan, Uganda, Zambia, and Zimbabwe., pp. 26–27; It has been given the index number H506.3 in Stith Thompson's motif index of folk literature, and is ATU 1579 in the Aarne–Thompson classification system.
Another variation of this puzzle appears in The Simpsons, season 20 episode 13 (Gone Maggie Gone), where Homer has to get across a river with Maggie, Santa's Little Helper, and a jar of rat poison (that looks like candy).
In some parts of Africa, variations on the puzzle have been found in which the boat can carry two objects instead of only one. When the puzzle is weakened in this way it is possible to introduce the extra constraint that no two items, including A and C, can be left together., p. 27.
See also 
- Pressman, Ian; David Singmaster (June 1989). ""The Jealous Husbands" and "The Missionaries and Cannibals"". The Mathematical Gazette (The Mathematical Association) 73 (464): 73–81. doi:10.2307/3619658. JSTOR 3619658.
- Ascher, Marcia (February 1990). "A River-Crossing Problem in Cross-Cultural Perspective". Mathematics Magazine (Mathematical Association of America) 63 (1): 26–29. doi:10.2307/2691506. JSTOR 2691506.
- Alcuin's Transportation Problems and Integer Programming, Ralf Borndörfer, Martin Grötschel, and Andreas Löbel, preprint SC-95-27 (November 1995), Konrad-Zuse-Zentrum für Informationstechnik Berlin.
- The Classic River Crossing Puzzle
- Mary Jane Sterling, Math Word Problems for Dummies, P.313
- Stewart, Ian (1998). The Magical Maze. Phoenix. ISBN 0-7538-0514-6.
- 235. Three Zande Texts, E. E. Evans-Pritchard, Man, 62 (October 1962), pp. 149–152.
- "Carrying a Wolf, a Goat, and a Cabbage across the Stream. Metamorphoses of ATU 1579", Piret Voolaid, Folklore: Electronic Journal of Folklore 35 (2007), pp. 111–130. Tartu: Eesti Kirjandusmuuseum.
- p. 17, Rediscovered Lewis Carroll Puzzles, Lewis Carroll, compiled by Edward Wakeling, Courier Dover Publications, 1996, ISBN 0-486-28861-7.
- Goat, Cabbage and Wolf A Java simulation