This Tic Tac Toe game is a command line application built in Ruby. The initial functionality permits gameplay between two human players. The program will exit when gameplay ends: either when a player has won, or if the game has reached a draw.
Clone this repo from the terminal:
git clone https://github.com/karen-olson/tic-tac-toe-basic
cd to the program directory & install dependencies:
bundle install
Initialize the guard auotmated test suite to use RSpec:
bundle exec guard init rspec
Run the linter:
bundle exec rubocop
To safely autocorrect correctable offenses:
bundle exec rubocop -a
Run tests:
bundle exec rspec
To start the automated test suite:
bundle exec guard
From program directory:
ruby bin/run
Enter the number (1-9) of the space on the board where you want to move. Player 1 moves first and marks their spaces with an “X”. Player 2 marks with an “O”. To win, claim 3 adjacent spaces in a horizontal, vertical, or diagonal line. If there are no free spaces and no player has won, the game will end in a draw.
- Add gameplay between a human player vs. AI player
- Allow user to select the order of players