Towers of Hanoi

Enter n (integer >=0):
Towers of Hanoi moves for rings.