Towers of Hanoi and Tic Tac Toe written in node.js