Advertisement
Guest User

Untitled

a guest
Feb 27th, 2017
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. package tictactoe;
  2.  
  3. import java.util.Scanner;
  4.  
  5. public class MainActivity {
  6.  
  7. public static void main(String[] args) {
  8. String player1Name;
  9. String player2Name;
  10.  
  11. // Create new scanner object
  12. Scanner userInput = new Scanner(System.in);
  13. // Get player names
  14. System.out.print("Player 1 Name:\t");
  15. player1Name = (userInput.nextLine() + " ");
  16. System.out.print("Player 2 Name:\t");
  17. player2Name = userInput.nextLine();
  18.  
  19. // Create the game board
  20. TicTacToeBoard gameBoard = new TicTacToeBoard(player1Name, player2Name);
  21. }
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement