Revert "hanoi algorithm for rotation implementation"

This reverts commit c32f4e4a7ea5f0b4b21a715d187332ec2b73bebe.