Skip to content

Latest commit

 

History

History
78 lines (46 loc) · 1.46 KB

README.md

File metadata and controls

78 lines (46 loc) · 1.46 KB

Tic-Tac-Toe with AI 🤖

Welcome to Tic-Tac-Toe with AI! This project implements the classic game of Tic-Tac-Toe with two modes:

  1. 🎮 Play against an AI opponent.
  2. 👫 Play with a friend.

Features

  • 🧠 AI Mode:

    • Challenge a computer opponent with a strategy to minimize losses.
  • 👥 Two-Player Mode:

    • Play locally with a friend.
  • 🎨 Interactive UI:

    • A visually appealing interface for easy gameplay.
  • 🔁 Replay Option:

    • Restart the game after every match.

Technologies Used

  • 💻 Python
  • 🤖 AI Algorithm: Minimax algorithm

Playing the Game

  1. Clone the Repository:

    git clone https://github.com/omarmohamedreda/Tic-Tac-toe-using-AI.git
  2. Navigate to the Project Directory:

    cd Tic-Tac-toe-using-AI
  3. Open the Game:

    • Open the index.html file in your preferred web browser.
  4. 🎉 Start playing Tic-Tac-Toe!


How It Works

  • Minimax Algorithm:
    • The AI evaluates all possible moves to make the best decision, ensuring an unbeatable opponent.

Contributions

Contributions are welcome! Here’s how you can contribute:

  1. 🍴 Fork the repository.
  2. 🌱 Create a new branch.
  3. ✨ Make your changes and commit them.
  4. 🔄 Submit a pull request.

Author

Created by Omar Mohamed. Feel free to connect with me for collaborations, feedback, or opportunities.