package is.ru.tictactoe;
import java.util.Scanner;

public class TicTacToeConsole {
  public static void main(String[] args){
    Scanner scanner = new Scanner(System.in);
    String player1Name = getName(1, scanner);
    String player2Name = getName(2, scanner);
    Player player1 = new Player(player1Name, Symbol.CROSS);
    Player player2 = new Player(player2Name, Symbol.CIRCLE);
    play(player1, player2, scanner);
    scanner.close();
  }

  private static void play(Player player1, Player player2, Scanner scanner){
    TicTacToe game = new TicTacToe(player1, player2);
    Player player = player1;
    final int SIZE = game.getBoard().SIZE;
    for(int i = 0; i < SIZE*SIZE; i++){
      char[][] board = game.getBoard().getBoard();;
      printBoard(board, SIZE);
      System.out.print(player.getName() + ", where do you want to put your " + game.getNextTurn().toString().toLowerCase() + ": ");
      int n = scanner.nextInt();
      game.makeMove(n);
      player = switchPlayer(player1, player2, player);
    }
  }

  private static void printBoard(char[][] board, int SIZE){
    System.out.println();
    for (int i = 0; i < SIZE; i++) {
      for (int j = 0; j < SIZE; j++) {
        System.out.print(board[i][j] + " ");
      }
      System.out.println();
    }
  }

  private static Player switchPlayer(Player player1, Player player2, Player player){
    if(player == player1){
       return player2;
    }
    return player1;
  }

  private static String getName(int number, Scanner scanner){
    System.out.println("Player " + number + " what is your name?");
    String name = scanner.nextLine();
    return name;
  }
}

@@ -690,24 +690,21 @@
 %7B%0A      
-char%5B%5D%5B%5D
+Board
  board =
@@ -723,20 +723,8 @@
 rd()
-.getBoard();
 ;%0A  
@@ -902,24 +902,31 @@
 n = 
-scanner.nextInt(
+getInput(scanner, board
 );%0A 
@@ -1051,34 +1051,62 @@
 ard(
-char%5B%5D%5B%5D board, int SIZE)%7B
+Board b, int SIZE)%7B%0A    char%5B%5D%5B%5D board = b.getBoard();
 %0A   
@@ -1288,32 +1288,679 @@
 n();%0A    %7D%0A  %7D%0A%0A
+  private static int getInput(Scanner scanner, Board board) %7B%0A    int input;%0A    do%7B%0A      checkIfInt(scanner);%0A      input = scanner.nextInt();%0A      if(board.isTaken(input))%7B%0A        System.out.print(%22This spot is taken, please choose another one: %22);%0A      %7D%0A      else if(!board.checkValidMove(input))%7B%0A        System.out.print(%22Please enter a number between 1 and 9: %22);%0A      %7D%0A    %7Dwhile(board.isTaken(input) %7C%7C !board.checkValidMove(input));%0A%0A    return input;%0A  %7D%0A%0A  private static void checkIfInt(Scanner scanner)%7B%0A    while(!scanner.hasNextInt())%7B%0A      System.out.print(%22Please enter a valid input: %22);%0A      scanner.next();%0A    %7D%0A  %7D%0A
   private static

Put in same validation as in the old console class