Search/Recent Changes
DBTropes
...it's like TV Tropes, but LINKED DATA!

Towers of Hanoi

 Towers of Hanoi
type
FeatureClass
 Towers of Hanoi
label
Towers of Hanoi
 Towers of Hanoi
page
TowersOfHanoi
 Towers of Hanoi
comment
A classic Stock Puzzle, invented in 1883 by Edouard Lucas. The player is given three poles in a row, and at least three discs of different sizes stacked on the pole on one side. The objective is to get the discs from the pole on one side to the pole on the other by moving the discs, one at a time, from one pole to another, in as few moves as possible. The player can only move the top disc on any stack, and cannot place a bigger disc on a smaller disc.
There is an (apocryphal) legend about a tower in... well, Hanoi where the priests of Brahma, in accordance with an ancient prophecy, basically spend their time playing the game... with 64 disks of solid gold. Furthermore, the prophecy states that when the puzzle is finally solved, the world will end. The legend was invented by Lucas himself when he distributed the original puzzle under the Significant Anagram N. Claus (De Siam), for E. Lucas (D'Amiens). Note that if this legend were true, even if the priests were able to move one disc per second, it would take 584,942,417,356 years, 26 days, 7 hours and 15 seconds for them to solve it — making it a scientifically accurate prophecy; the sun would have exploded around the time the puzzle becomes 1% complete.
Often used as an introduction to the concept of recursion in programming classes. Solving it requires moving n-1 discs onto the vacant pole, then the nth disc onto the target, then the previous pile of n-1 discs on top of that one, thus requiring a total of (2^n)-1 moves. It's also a common, seemingly random obstacle in video games.
The recursive solution is, roughly:
If there is only one disk move it directly from the source peg to the target peg. Otherwise:
Ignore the bottom disk of the tower on the source peg, and solve the Towers of Hanoi problem from the source peg to the spare peg, using the target peg as a spare. The spare peg now has a tower of n-1 disks on it, and the source peg has one disk (the biggest) on it.
Move the single disk from the source peg to the target peg.
Solve the Towers of Hanoi problem from the spare peg to the target peg using the source peg as a spare.
This counts as a solution because the "solve the Towers of Hanoi" steps in (2) and (4) are for towers one disk smaller than the previous. Solving the problem for n disks can be done if you know how to do it for n-1 disks, which can be done if you know how to do it for n-2 disks, et cetera... until you get down to doing it for one disk, which is trivial.
If the disks are numbered, human solvers can use as a memory aid the fact that it is never correct to place an odd-numbered disk directly on top of another odd-numbered disk, and likewise for even-numbered disks.
Amusingly, at least one Brahmin monastery has adopted the puzzle as a genuine devotional exercise, using approximately 30 brass discs.note A 30-disk tower would take a bit over 34 years to solve at the rate of one disk per second. No word if the puzzle's completion will mark the end of the current universe.
 Towers of Hanoi
fetched
2023-11-04T19:14:51Z
 Towers of Hanoi
parsed
2023-11-04T19:14:51Z
 Towers of Hanoi
processingComment
Dropped link to EpilepticTrees: Not an Item - FEATURE
 Towers of Hanoi
processingComment
Dropped link to HiddenObjectGame: Not an Item - FEATURE
 Towers of Hanoi
processingComment
Dropped link to InteractiveFiction: Not an Item - FEATURE
 Towers of Hanoi
processingComment
Dropped link to StarWars: Not an Item - CAT
 Towers of Hanoi
isPartOf
DBTropes
 Towers of Hanoi / int_12f6bcb
type
Towers of Hanoi
 Towers of Hanoi / int_12f6bcb
comment
Towers of Hanoi featured as an Aztec Zone game in the second series of The Crystal Maze.
 Towers of Hanoi / int_12f6bcb
featureApplicability
1.0
 Towers of Hanoi / int_12f6bcb
featureConfidence
1.0
 The Crystal Maze
hasFeature
Towers of Hanoi / int_12f6bcb
 Towers of Hanoi / int_148f217e
type
Towers of Hanoi
 Towers of Hanoi / int_148f217e
comment
All the time in the Nancy Drew series. There's one in The Haunting of Castle Malloy that springs to mind first.
 Towers of Hanoi / int_148f217e
featureApplicability
1.0
 Towers of Hanoi / int_148f217e
featureConfidence
1.0
 Nancy Drew (Video Game)
hasFeature
Towers of Hanoi / int_148f217e
 Towers of Hanoi / int_1c296808
type
Towers of Hanoi
 Towers of Hanoi / int_1c296808
comment
"Bright Eyes", the ape in Rise of the Planet of the Apes, is seen flying through this puzzle, though it was a four disc variant and she was tested on it repeatedly.
 Towers of Hanoi / int_1c296808
featureApplicability
1.0
 Towers of Hanoi / int_1c296808
featureConfidence
1.0
 Rise of the Planet of the Apes
hasFeature
Towers of Hanoi / int_1c296808
 Towers of Hanoi / int_22dfb2a
type
Towers of Hanoi
 Towers of Hanoi / int_22dfb2a
comment
In the video game adaptation of All Dogs Go to Heaven (which is a Minigame Game), there is a Towers of Hanoi-styled minigame.
 Towers of Hanoi / int_22dfb2a
featureApplicability
1.0
 Towers of Hanoi / int_22dfb2a
featureConfidence
1.0
 All Dogs Go to Heaven
hasFeature
Towers of Hanoi / int_22dfb2a
 Towers of Hanoi / int_2405b546
type
Towers of Hanoi
 Towers of Hanoi / int_2405b546
comment
The stairway puzzle in Ultima VIII is a version with stair steps.
 Towers of Hanoi / int_2405b546
featureApplicability
1.0
 Towers of Hanoi / int_2405b546
featureConfidence
1.0
 Ultima VIII (Video Game)
hasFeature
Towers of Hanoi / int_2405b546
 Towers of Hanoi / int_26790775
type
Towers of Hanoi
 Towers of Hanoi / int_26790775
comment
The third screen in The Island of Dr. Brain has this puzzle with 4, 5, or 7 discs, depending on the difficulty. Expect to be there a while on Expert difficulty making 127 moves.
 Towers of Hanoi / int_26790775
featureApplicability
1.0
 Towers of Hanoi / int_26790775
featureConfidence
1.0
 Dr. Brain (Video Game)
hasFeature
Towers of Hanoi / int_26790775
 Towers of Hanoi / int_27585deb
type
Towers of Hanoi
 Towers of Hanoi / int_27585deb
comment
In Lonesome Village, the Nu View puzzle is based on this, with the player using a miniature consisting of three pins and three discs to change the position of a much larger set of discs placed on three pillars in the room. By moving all the discs to the rightmost pillar, the path to the puzzle's treasure is opened.
 Towers of Hanoi / int_27585deb
featureApplicability
1.0
 Towers of Hanoi / int_27585deb
featureConfidence
1.0
 Lonesome Village (Video Game)
hasFeature
Towers of Hanoi / int_27585deb
 Towers of Hanoi / int_2ac38f3a
type
Towers of Hanoi
 Towers of Hanoi / int_2ac38f3a
comment
My Hero Playthrough: Izuku encounters this as an obstacle in the Labyrinth (first round of the Sports Festival). He solves it before the puzzle finishes revealing itself. He says he as seen it so many times in games, he can solve it in his sleep.
 Towers of Hanoi / int_2ac38f3a
featureApplicability
1.0
 Towers of Hanoi / int_2ac38f3a
featureConfidence
1.0
 My Hero Playthrough (Fanfic)
hasFeature
Towers of Hanoi / int_2ac38f3a
 Towers of Hanoi / int_39fe00f1
type
Towers of Hanoi
 Towers of Hanoi / int_39fe00f1
comment
Dragon Age: Inquisition's Descent DLC features the "Builder's Towers" puzzle as an optional sidequest, but still lampshades its infamy by having your character call it insane.
 Towers of Hanoi / int_39fe00f1
featureApplicability
1.0
 Towers of Hanoi / int_39fe00f1
featureConfidence
1.0
 DragonAgeInquisition
hasFeature
Towers of Hanoi / int_39fe00f1
 Towers of Hanoi / int_4c56381b
type
Towers of Hanoi
 Towers of Hanoi / int_4c56381b
comment
The Binding of Isaac: The Repentance+ Game Mod adds an activated item called Tower of Babel, based on this puzzle. When activated, it destroys all obstacles in the current room, referencing the supposed end-of-the-world prophecy surrounding towers of Hanoi.
 Towers of Hanoi / int_4c56381b
featureApplicability
1.0
 Towers of Hanoi / int_4c56381b
featureConfidence
1.0
 The Binding of Isaac (Video Game)
hasFeature
Towers of Hanoi / int_4c56381b
 Towers of Hanoi / int_4fcf7c84
type
Towers of Hanoi
 Towers of Hanoi / int_4fcf7c84
comment
One of the activities in Math Blaster: Pre-Algebra is a variation on the Towers of Hanoi where barrels in the basement must be stacked to solve a math problem. Rather than varying sizes of barrels, it uses varying numbers on the barrels which must add up to the number on the platform. There are three places to put the barrels and four barrels. There are two platforms which may or may not have different numbers.
 Towers of Hanoi / int_4fcf7c84
featureApplicability
1.0
 Towers of Hanoi / int_4fcf7c84
featureConfidence
1.0
 Blaster Mystery Series (Video Game)
hasFeature
Towers of Hanoi / int_4fcf7c84
 Towers of Hanoi / int_629cd094
type
Towers of Hanoi
 Towers of Hanoi / int_629cd094
comment
In Dragon Age: Origins, it is instead mocked by a gravestone in Haven reading "T.O. Hanoi. Unloved, unmourned."
 Towers of Hanoi / int_629cd094
featureApplicability
1.0
 Towers of Hanoi / int_629cd094
featureConfidence
1.0
 Dragon Age: Origins (Video Game)
hasFeature
Towers of Hanoi / int_629cd094
 Towers of Hanoi / int_6ee9416d
type
Towers of Hanoi
 Towers of Hanoi / int_6ee9416d
comment
This is the last puzzle in The Legend of Kyrandia: Hand of Fate.
 Towers of Hanoi / int_6ee9416d
featureApplicability
1.0
 Towers of Hanoi / int_6ee9416d
featureConfidence
1.0
 The Legend of Kyrandia (Video Game)
hasFeature
Towers of Hanoi / int_6ee9416d
 Towers of Hanoi / int_7668653b
type
Towers of Hanoi
 Towers of Hanoi / int_7668653b
comment
One of the game machines seen in the arcade included in the Mass Effect 3 Citadel DLC is "Towers of Hanoi." Shepard's reaction: "I don't think so," likely a reference to its appearance in the first game.
 Towers of Hanoi / int_7668653b
featureApplicability
1.0
 Towers of Hanoi / int_7668653b
featureConfidence
1.0
 Mass Effect 3 (Video Game)
hasFeature
Towers of Hanoi / int_7668653b
 Towers of Hanoi / int_7870fd09
type
Towers of Hanoi
 Towers of Hanoi / int_7870fd09
comment
To finish Zork Zero, the player has to go through this twice (at least). Even nastier, you're not allowed to save while in the room, and if you put a big disc onto a smaller one, it crushes the smaller one, making the game Unwinnable. Hope you saved often!
 Towers of Hanoi / int_7870fd09
featureApplicability
1.0
 Towers of Hanoi / int_7870fd09
featureConfidence
1.0
 Zork Zero (Video Game)
hasFeature
Towers of Hanoi / int_7870fd09
 Towers of Hanoi / int_79a57c7e
type
Towers of Hanoi
 Towers of Hanoi / int_79a57c7e
comment
A side quest in Black & White has you doing this to move a temple further up the shore of a lake so it doesn't get flooded out during high tide, and livens up the experience by having the owner loudly complain about the destruction of his delicate furniture with every move. The inclusion of "classic" puzzles caused some reviewers to wonder whether Hanoi Towers and garbage collecting is really what gods do.
 Towers of Hanoi / int_79a57c7e
featureApplicability
1.0
 Towers of Hanoi / int_79a57c7e
featureConfidence
1.0
 Black & White (Video Game)
hasFeature
Towers of Hanoi / int_79a57c7e
 Towers of Hanoi / int_7d8c61a2
type
Towers of Hanoi
 Towers of Hanoi / int_7d8c61a2
comment
But used again (repeatedly) in Star Wars: The Old Republic, where the puzzle is part of the activation of a plasma vent used in the penultimate Boss Fight of Karagga's Palace.
 Towers of Hanoi / int_7d8c61a2
featureApplicability
1.0
 Towers of Hanoi / int_7d8c61a2
featureConfidence
1.0
 Star Wars: The Old Republic (Video Game)
hasFeature
Towers of Hanoi / int_7d8c61a2
 Towers of Hanoi / int_83d85959
type
Towers of Hanoi
 Towers of Hanoi / int_83d85959
comment
Appears in its four-tier form in Mystery of Mortlake Mansion.
 Towers of Hanoi / int_83d85959
featureApplicability
1.0
 Towers of Hanoi / int_83d85959
featureConfidence
1.0
 Mystery Of Mortlake Mansion (Video Game)
hasFeature
Towers of Hanoi / int_83d85959
 Towers of Hanoi / int_9ee4ebeb
type
Towers of Hanoi
 Towers of Hanoi / int_9ee4ebeb
comment
A side mission to explore an abandoned mansion in Space Rangers 2 has this as one of the puzzles.
 Towers of Hanoi / int_9ee4ebeb
featureApplicability
1.0
 Towers of Hanoi / int_9ee4ebeb
featureConfidence
1.0
 Space Rangers (Video Game)
hasFeature
Towers of Hanoi / int_9ee4ebeb
 Towers of Hanoi / int_9f02efb1
type
Towers of Hanoi
 Towers of Hanoi / int_9f02efb1
comment
EverQuest has a quest where you have to play Towers of Hanoi, although they don't call it that.
 Towers of Hanoi / int_9f02efb1
featureApplicability
1.0
 Towers of Hanoi / int_9f02efb1
featureConfidence
1.0
 EverQuest (Video Game)
hasFeature
Towers of Hanoi / int_9f02efb1
 Towers of Hanoi / int_9fdbe999
type
Towers of Hanoi
 Towers of Hanoi / int_9fdbe999
comment
The final mission of The Challenge season 5: Battle of the Seasons included a Towers of Hanoi puzzle; the Real World team's quick completion of this puzzle allowed them to come from behind to win the final prize.
 Towers of Hanoi / int_9fdbe999
featureApplicability
1.0
 Towers of Hanoi / int_9fdbe999
featureConfidence
1.0
 The Challenge
hasFeature
Towers of Hanoi / int_9fdbe999
 Towers of Hanoi / int_a7f2f663
type
Towers of Hanoi
 Towers of Hanoi / int_a7f2f663
comment
One of the puzzles among the final trio of minigames near the end of Reah: Face the Unknown. This one plays it from the reverse angle (smallest in the back, largest in front). But it's annoying in the fact that, like the other two puzzles, you have to do three rounds of it, each one containing more pieces than the last.
 Towers of Hanoi / int_a7f2f663
featureApplicability
1.0
 Towers of Hanoi / int_a7f2f663
featureConfidence
1.0
 Reah: Face the Unknown (Video Game)
hasFeature
Towers of Hanoi / int_a7f2f663
 Towers of Hanoi / int_ae2271fc
type
Towers of Hanoi
 Towers of Hanoi / int_ae2271fc
comment
Diamond Alice's minigame in Later Alligator involves moving a stack of pancakes onto her favorite plate, with the stack getting bigger each round. Making too many moves without solving the puzzle will cause you to fail the minigame, but there are four plates instead of three, making it easier to solve.
 Towers of Hanoi / int_ae2271fc
featureApplicability
1.0
 Towers of Hanoi / int_ae2271fc
featureConfidence
1.0
 Later Alligator (Video Game)
hasFeature
Towers of Hanoi / int_ae2271fc
 Towers of Hanoi / int_c43df4d8
type
Towers of Hanoi
 Towers of Hanoi / int_c43df4d8
comment
In the Doctor Who serial "The Celestial Toymaker" (now a lost story except for the final episode, but available in full on audio), the Doctor is challenged to solve a 10-disc version of the Towers of Hanoi, known as The Trilogic Game. The Doctor realises that the Toymaker's world will vanish once he makes the last move, so he finishes it inside the TARDIS.
 Towers of Hanoi / int_c43df4d8
featureApplicability
1.0
 Towers of Hanoi / int_c43df4d8
featureConfidence
1.0
 Doctor Who
hasFeature
Towers of Hanoi / int_c43df4d8
 Towers of Hanoi / int_d017e09d
type
Towers of Hanoi
 Towers of Hanoi / int_d017e09d
comment
Sunless Sea: The Emperor's Tomb in the Empire of Hands has this puzzle as one of the various obstacles, in this case acting as the door's lock. It's lampshaded as an easy and overused Stock Puzzle, matching with the general mockery of jungle temple tropes in this mission, but this one also has 15 disksnote 32,767 moves, making it horribly tedious and it's also badly-made, and won't actually open the door when it's solved. Fortunately, you brought dynamite.
 Towers of Hanoi / int_d017e09d
featureApplicability
1.0
 Towers of Hanoi / int_d017e09d
featureConfidence
1.0
 Sunless Sea (Video Game)
hasFeature
Towers of Hanoi / int_d017e09d
 Towers of Hanoi / int_d4d00d1c
type
Towers of Hanoi
 Towers of Hanoi / int_d4d00d1c
comment
Carto gives three versions in the Story Chalet: a 2-box, a 4-box, and a 10-box. (Fortunately, the last one has a shortcut.)
 Towers of Hanoi / int_d4d00d1c
featureApplicability
1.0
 Towers of Hanoi / int_d4d00d1c
featureConfidence
1.0
 Carto (Video Game)
hasFeature
Towers of Hanoi / int_d4d00d1c
 Towers of Hanoi / int_d6b6971d
type
Towers of Hanoi
 Towers of Hanoi / int_d6b6971d
comment
Survivor:
In Thailand (U.S. season 5), a large five-disk version of this puzzle was an immunity challenge. One competitor, Shii Ann, a computer programmer, seemed to have no clue at all of how to solve it, leading to some Epileptic Trees from fans about both her meta-game strategy and the actual backstage operations of the show
It appears as the opening challenge of Survivor: South Pacific (U.S. season 23).
 Towers of Hanoi / int_d6b6971d
featureApplicability
1.0
 Towers of Hanoi / int_d6b6971d
featureConfidence
1.0
 Survivor
hasFeature
Towers of Hanoi / int_d6b6971d
 Towers of Hanoi / int_d7062bae
type
Towers of Hanoi
 Towers of Hanoi / int_d7062bae
comment
Getting caught by Dr. X's minions in Jumpstart 5th Grade involves doing this with a stack of wooden crates to reach a broken window. Higher difficulty levels results in more crates to deal with.
 Towers of Hanoi / int_d7062bae
featureApplicability
1.0
 Towers of Hanoi / int_d7062bae
featureConfidence
1.0
 JumpStart Adventures 5th Grade: Jo Hammet, Kid Detective (Video Game)
hasFeature
Towers of Hanoi / int_d7062bae
 Towers of Hanoi / int_e5d48bf6
type
Towers of Hanoi
 Towers of Hanoi / int_e5d48bf6
comment
Umang has to play a game of this in The Sacred Rings using Russian doll-style statues, to place in the proper slot so Reina can summon lightning for him.
 Towers of Hanoi / int_e5d48bf6
featureApplicability
1.0
 Towers of Hanoi / int_e5d48bf6
featureConfidence
1.0
 Aura (Video Game)
hasFeature
Towers of Hanoi / int_e5d48bf6
 Towers of Hanoi / int_ea377bc0
type
Towers of Hanoi
 Towers of Hanoi / int_ea377bc0
comment
In the System Shock fanfic Free Radical, a robot was set to do a twenty-piece version to prevent SHODAN from being able to connect to it when it went for new orders.
 Towers of Hanoi / int_ea377bc0
featureApplicability
1.0
 Towers of Hanoi / int_ea377bc0
featureConfidence
1.0
 System Shock (Video Game)
hasFeature
Towers of Hanoi / int_ea377bc0
 Towers of Hanoi / int_f10b72a4
type
Towers of Hanoi
 Towers of Hanoi / int_f10b72a4
comment
3-D Ultra Lionel Traintown has a Tower of Hanoi puzzle as one of the game's missions, which is played with train cars.
 Towers of Hanoi / int_f10b72a4
featureApplicability
1.0
 Towers of Hanoi / int_f10b72a4
featureConfidence
1.0
 3-D Ultra Lionel Traintown (Video Game)
hasFeature
Towers of Hanoi / int_f10b72a4
 Towers of Hanoi / int_f6bb880b
type
Towers of Hanoi
 Towers of Hanoi / int_f6bb880b
comment
Professor Layton and the Diabolical Box, which uses pancakes in place of discs and plates instead of pegs.
 Towers of Hanoi / int_f6bb880b
featureApplicability
1.0
 Towers of Hanoi / int_f6bb880b
featureConfidence
1.0
 Professor Layton (Video Game)
hasFeature
Towers of Hanoi / int_f6bb880b
 Towers of Hanoi / int_ffdbdf5d
type
Towers of Hanoi
 Towers of Hanoi / int_ffdbdf5d
comment
The Tire Tower puzzle in The Secret Island of Dr. Quandary. 3 tires as B. Ginner, 4 as O.D. Nary, 5 as D. Feecult, and each with a limit on the moves you can use before your time is up and Quandary kicks you out of the junkyard.
 Towers of Hanoi / int_ffdbdf5d
featureApplicability
1.0
 Towers of Hanoi / int_ffdbdf5d
featureConfidence
1.0
 The Secret Island of Dr. Quandary (Video Game)
hasFeature
Towers of Hanoi / int_ffdbdf5d

The following is a list of statements referring to the current page from other pages.

 Towers of Hanoi
processingCategory2
Stock Puzzle
 My Hero Playthrough (Fanfic) / int_bc2717e9
type
Towers of Hanoi
 Die Hard with a Vengeance / int_bc2717e9
type
Towers of Hanoi
 Rise of the Planet of the Apes / int_bc2717e9
type
Towers of Hanoi
 Adventure Escape (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Blaster Mystery Series (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Carmen Sandiego: Word Detective (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Carto (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Dr. Brain (Video Game) / int_bc2717e9
type
Towers of Hanoi
 JumpStart Adventures 5th Grade: Jo Hammet, Kid Detective (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Knights of the Old Republic (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Later Alligator (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Lonesome Village (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Professor Layton (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Sunless Sea (Video Game) / int_bc2717e9
type
Towers of Hanoi
 The Legend of Kyrandia (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Those Games (Video Game) / int_bc2717e9
type
Towers of Hanoi
 3-D Ultra Lionel Traintown (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Ultima VIII (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Zork Zero (Video Game) / int_bc2717e9
type
Towers of Hanoi
 Phi Brain: Puzzle of God / int_bc2717e9
type
Towers of Hanoi