Skip to content

alycerios/Tic-Tac-Toe-challenge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

Tic-Tac-Toe-challenge

TTTgame-AR

Description

TTTgame-AR.py is a Python script for a Tic-Tac-Toe game. The game allows two players to play Tic-Tac-Toe on a 3x3 board, with options for a player vs. computer mode.
I spent 1 hour and 30 minutes creating this code for the 'Tic-Tac-Toe' Challenge.

Features

  • Two-player mode or player vs. computer.
  • Simple command-line interface.
  • The game board displays as blank only when the user is the first one playing.
  • The game board is displayed after each move.
  • The game does not allow the user or computer to overwrite a previous mark.
  • The game provides feedback if an invalid move is attempted, including out-of-range or already occupied positions.
  • Checks for win, loss, or tie conditions when the board is full and no one has won.
  • Offers the user the chance to play again.
  • Handles exceptions.

Requirements

  • Python 3.x

Setup Instructions

  1. Clone the repository:

    git clone https://github.com/alycerios/Tic-Tac-Toe-challenge.git
    
  2. Navigate to the Directory: cd Tic-Tac-Toe-challenge

  3. Create a virtual environment to run the code python -m venv venv

  4. Activating the virtual environment in Windows .\venv\Scripts\activate

  5. Run the game: To run the game, execute the Python script: python TTTgame-AR.py (assuming python points to Python 3.x, if not use 'python 3').

No external dependencies for this project:

As of now, there are no external libraries required for running this script.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages