Play the classic Башня of Ханой puzzle online. Move disks between pegs following the rules. Choose your difficulty and solve it in minimum moves. Бесплатный, no signup.
The Башня of Ханой is a mathematical puzzle invented by the French mathematician Édouard Lucas in 1883. It consists of three pegs and a number of disks of different sizes which can slide onto any peg. The puzzle starts with the disks stacked in ascending order of size on one peg, and the objective is to move the entire stack to another peg, obeying specific rules. The minimum number of moves required to solve the puzzle is 2^n − 1, where n is the number of disks.
The minimum number of moves to solve the Башня of Ханой with n disks is 2^n − 1. For example: 3 disks = 7 moves, 4 disks = 15 moves, 5 disks = 31 moves, 6 disks = 63 moves, 7 disks = 127 moves, and 8 disks = 255 moves.
Yes. The proof uses mathematical induction. To move n disks from peg A to peg C, you must first move n−1 disks to peg B (taking T(n−1) moves), then move the largest disk to peg C (1 move), then move the n−1 disks from peg B to peg C (another T(n−1) moves). This gives the recurrence T(n) = 2T(n−1) + 1, which solves to T(n) = 2^n − 1.
No. The minimum number of moves (2^n − 1) is proven to be both necessary and sufficient. Any solution requires at least this many moves, and there exists a strategy that achieves exactly this number.
For the physical puzzle with 8 disks, skilled solvers can complete it in under 2 minutes. In competitive programming, computers can solve it instantly for any practical number of disks using the recursive algorithm.