What is Towers of Hanoi in Data structures
Towers of Hanoi can be easily implemented using recursion. Objective of the problem is moving a collection of N disks of decreasing size from one pillar to another pillar. The movement of the disk is restricted by the following rules. Rule 1 : Only one disk could be moved at a time. Rule 2 : […]