The earliest known published version of it comes from a manuscript dated to around 1730 (but it differs in referring to "nine" rather than "seven" wives). The modern form was first printed around 1825. A similar problem appears in the Rhind Mathematical Papyrus (Problem 79), dated to around 1650 BC, which could be described with the following text:
There are seven houses;
In each house there are seven cats;
Each cat catches seven mice;
Each mouse would have eaten seven ears of corn;
If sown, each ear of corn would have produced seven hekat of grain.
There are a number of places called St Ives in England and elsewhere. It is generally thought that the rhyme refers to St Ives, Cornwall, when it was a busy fishing port and had many cats to stop the rats and mice destroying the fishing gear, although some people argue it was St Ives, Huntingdonshire as this is an ancient market town and therefore an equally plausible destination.
All potential answers to this riddle are based on its ambiguity because the riddle only tells us the group has been "met" on the journey to St. Ives and gives no further information about its intentions, only those of the narrator. As such, any one of the following answers is plausible, depending on the intention of the other party:
1: If the group that the narrator meets is assumed not to be travelling to St. Ives (this is the most common assumption), the answer would be one person going to St. Ives: the narrator.
2802: If the narrator met the group as they were also travelling to St. Ives (and were overtaken by the narrator, plausible given the large size of the party), the answer in this case is all are going to St. Ives; see below for the mathematical answer.
2800: If the narrator and the group were all travelling to St. Ives, the answer could also be all except the narrator and the man, since the penultimate line of the rhyme specifies "kits, cats, sacks and wives". Thus the question is ambiguous about whether it is asking for the total number of entities travelling or just the number of kits, cats, sacks and wives. This would give an answer of 2800 — 2 fewer than the answer above.
2: Two is also a plausible answer. This would involve the narrator meeting the man who is assumed to be travelling to St. Ives also, but plays on a grammatical uncertainty, since the riddle states only that the man has seven wives (and so forth), but does not explicitly mention whether the man is actually accompanied by his wives, sacks, cats, and kittens.
0: Yet another plausible answer is zero, once again playing on a grammatical uncertainty. The last line of the riddle states "kits, cats, sacks, wives ... were going to St. Ives?" Although the narrator clearly states he is going to St. Ives, by definition he is not one of the kits, cats, sacks, or wives, and based on the common assumption that the party was not going to St. Ives, the answer is zero.
2753: The sacks are not a person or animal and therefore cannot be in the calculation. It was not the number of things, but of "persons" the narrator met. 49 adult cats 343 kittens per wife of whom he had seven (7 × 392) = 2744 plus the seven wives 2751 plus the man + the narrator → 2753 persons and animals.
9: There are nine people involved, who may be going to St. Ives. The animals are all in the sacks, so they, as well as the sacks themselves, are "being taken", rather than "going".
7: There are nine people involved, who are the only ones who may be going to St. Ives, all the others "being taken" there. But since the question is limited to "Kits, cats, sacks, wives", this excludes the man and the narrator, leaving seven.
At least 1: With any certainty [as demonstrated by the multitude of possibilities above] we can only know that at least 1 person was traveling to St. Ives.
The problem appears to be an illustration of an algorithm for multiplying numbers. The sequence 7, 7 × 7, 7 × 7 × 7, ..., appears in the right-hand column, and the terms 2,801, 2 × 2,801, 4 × 2,801 appear in the left; the sum on the left is 7 × 2,801 = 19,607, the same as the sum of the terms on the right. Note that the author of the papyrus listed a wrong value for the fourth power of 7; it should be 2,401, not 2,301. However, the sum of the powers (19,607) is correct.
The problem has been paraphrased by modern commentators as a story problem involving houses, cats, mice, and grain, although in the Rhind Mathematical Papyrus there is no discussion beyond the bare outline stated above. The hekat was 1⁄30 of a cubic cubit (approximately 4.8 l or 1.1 imp gal; 1.3 US gal).
Use in popular culture
In the 1995 filmDie Hard with a Vengeance, the rhyme is presented to the protagonists by the villain as a riddle, giving them thirty seconds to telephone him on the number "555 plus the answer" or a bomb would detonate. The protagonists initially believe the answer to be 2401, only solving for the number of kits. However, they eventually solve the riddle, calling the number 555–0001 which proves to be correct. They missed the 30-second deadline, but the bomb did not explode since the villain had not said "Simon says."
The rhyme was recited by Mary Murphy's character while caring for a cat with seven kittens in the movie A Man Alone. Later the character played by Ray Milland who overheard the rhyme offers her the answer and Murphy's character explains that she alone was going to St. Ives.
The rhyme was also the basis of a Sesame Street Muppet skit from the show's first season, in which the boy Muppet holding a numeral 7 sings the rhyme as a song to the girl Muppet twice (the second time, the girl is busy writing down the calculations) and finally, in keeping true to the spirit of the riddle, reveals the answer as 1 (the traditional answer), because he was going to St. Ives and the kits, cats, sacks and wives were going the other way. Then the girl turns the tables on the boy and asks how many were going the other way. She then reveals the mathematical answer from her calculations: 1 man + 7 wives + 49 sacks + 343 cats + 2,401 kittens, which comes to 2,801. Astonished, the boy responds, "How about that?!"
The rhyme was also featured in a Pogo comic story, "More Mother Goosery Rinds" in which Albert Alligator himself portrays Mother Goose and Pogo a traveling musician. After going over several Mother Goose rhymes they get to the St. Ives riddle, albeit replacing "seven" with "forty" and while Albert (Mother Goose) keeps trying to cogitate the answer, Pogo boasts he knows it...and he answers "one", which baffles "Mother Goose" (Albert Alligator). Pogo says that if the kits, cats, sacks and wives weren't going to St. Ives, maybe they were going somewhere else, such as Altoona, Pennsylvania. So Albert again recites the riddle, this time ending with "Kits, cats, sacks, wives, how many were going to...ALTOONA??" But by this time, Pogo has already gone upon his way.
Mad magazine used it in at least two articles over the years for the following parodies:
British poet and humorist Colin West wrote a satire on "As I was going to St Ives", called "As I Went Down To Milton Keynes". The items listed are "a king with seven queens", and for every queen a prince, for every prince a princess, for every princess an earl, for every earl a lady, for every lady a baby, and for every baby a cat.
A variant of the riddle also appears in an optional side quest in the video game "Silent Hill 3" when the player plays the game on the riddle difficulty Hard. It is use to obtain a part of a code which can be used to unlock extra in-game content.
Another variant of the riddle appears in a side quest in the game Star Wars: Knights of the Old Republic in which the player, during a game of riddles, can pose the question of "How many are flying to Dantooine?" to win the game. The items listed are "five ships, each ship has five crewmen, each crewman has five pets".