# Question: code in c which will work on tower of hanoi...

###### Question details

Code in C++ which will work on Tower of Hanoi with 4 Pegs(Towers) using Frame and Steware Fornula e.g

•**First move upper k from A to B with the help of C &
D**

•**Rest move from A to D with the help of C**

•**Last move k from B to D with help of A &
C **

k= ⌊(√(8 *n + 1 ) - 1)/2⌋*

*MS(Mimimum steps)=[n-(K^2 (n)-K+2)/2]* 2^(k)+1