Solutions
Tower of Hanoi Solutions
Every move of the shortest solution, for each size people actually play — and for the sixty-four disks nobody ever will.
Pick a size. Each page plays the whole solution on a board, lists every move, and says what is particular about that number of disks.
| Disks | Moves | First move | At 1 move/second | Difficulty |
|---|---|---|---|---|
| 3 disks | 7 | A → C | 7 seconds | Easy |
| 4 disks | 15 | A → B | 15 seconds | Easy |
| 5 disks | 31 | A → C | 31 seconds | Medium |
| 6 disks | 63 | A → B | 1 minute | Medium |
| 7 disks | 127 | A → C | 2 minutes | Hard |
| 8 disks | 255 | A → B | 4 minutes | Hard |
| 9 disks | 511 | A → C | 8 minutes | Expert |
| 10 disks | 1,023 | A → B | 17 minutes | Expert |
| 64 disks | 18,446,744,073,709,551,615 | A → B | 585 billion years | — |
The first move alternates for a reason: the smallest disk circles A → C → B for an odd number of disks and A → B → C for an even number, and its first stop is the next tower on that circuit. Start it the wrong way and you can still finish — just not in the minimum.
Other sizes and positions
Past 10 disks the move lists run to thousands of rows. The solver plays any size up to 15, lists every move up to 12 disks and downloads the rest as a file, and solves from a half-finished position as well as from the start; the calculator gives the move count for any number of disks up to 200. Why every count is 2ⁿ − 1, and never less, is proved in why the minimum is 2ⁿ − 1.