fixed bugs in index and tictactoe.java, also created the function initialized