Refactor TicTacToe and make staticmethods