/TicTacToe

Ruby based TicTacToe command line game

Primary LanguageRuby

TicTacToe

This is a simple Tic-Tac-Toe command line game designed in Ruby. Players select spots based upon grid numbers and can visually see the moves that have been made.

Run this in the command terminal by typing the following in the working directory "ruby TicTacToe.rb"

Board Preview

Hello, please type the name of the first player: Sean
Thank you, and what is the name of the second player?: Bill
 
Ok, Sean will be X's
and Bill will be O's
 
Please type a number to select a position on the board: 
 
 1 | 2 | 3
---+---+---
 4 | 5 | 6
---+---+---
 7 | 8 | 9
 
 
The current board looks like this: 
 
   |   |  
---+---+---
   |   |  
---+---+---
   |   |  
 
Sean please select a move: