Xs and Os game with JavaScript