Skip to content

Commit

Permalink
Merge pull request #1 from jhaayushofficial/patch-5
Browse files Browse the repository at this point in the history
Create ayush
  • Loading branch information
BhumikaShivani2001 committed Oct 17, 2022
2 parents 35d3ace + 96f95dd commit 4f3056c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions ayush
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Tower of Hanoi is a mathematical puzzle where we have three rods (A, B, and C) and N disks. Initially, all the disks are stacked in decreasing value of diameter i.e., the smallest disk is placed on the top and they are on rod A. The objective of the puzzle is to move the entire stack to another rod (here considered C), obeying the following simple rules:

Only one disk can be moved at a time.
Each move consists of taking the upper disk from one of the stacks and placing it on top of another stack i.e. a disk can only be moved if it is the uppermost disk on a stack.
No disk may be placed on top of a smaller disk.

0 comments on commit 4f3056c

Please sign in to comment.