The Tower of Hanoi problem (also known as the Tower of Hanoi problem) is a well-known problem. There are n disks of different sizes on three pillars A, B, and C (assuming the radius is 1-n respectively). At the beginning, they are all stacked on Tower A (as shown in the figure). Your goal is to move all the disks from Tower A to Tower C within the minimum number of legal moves.
The rules for each step in the game are as follows:
1. Only one disk is allowed to be moved in each step (from the top of one pillar to the top of another pillar)
2. During the movement, you must ensure that the large disk cannot be on top of the small disk (the small one can be placed on top of the large one, and there cannot be any other size disks under the largest disk)