Towers of Hanoi

Where you start does not determine where you finish

This animation uses the <canvas> element and may not run in older versions of Internet Explorer.


Some Android (eg default) browsers can't render the site properly. We'll let you know if they fix the problem (41312). Or try another browser, eg Firefox.

Example showing propagation of child nodes.

Initially discs 1 to 3, 4 to 5, and 6 are grouped.

The first group passes disc 1 (but could pass disc 2 or no disc) to the second group ( which has one spare child node).

The second group passes disc 1 (but could pass disc 4 or no disc) to the third group (which has its one available child node spare)

The third group has no option to pass on any child disc

The reverse process has no option but to return any child nodes to their original parent node.