This project is an interactive Tic-Tac-Toe game with a customizable grid, implemented in Java with a web interface using HTML, CSS, and JavaScript. Players take turns placing X or O, aiming to form a winning line. The game supports real-time play and offers a simple, engaging way to enjoy this classic game.
- Customizable Board Size: Choose the size of the grid for a personalized challenge.
- Player Names: Enter player names for a personalized experience.
- Real-Time Play: Players alternate turns in real-time, with the interface reflecting changes instantly.
- Simple Web Interface: Play the game through an easy-to-use web interface.
- Java Development Kit (JDK) installed
- A web browser for the HTML interface
-
Clone the Repository:
git clone https://github.com/hrish7kesh/TicTacToe.git
-
Navigate to the Project Directory: cd TicTacToe
-
Compile and Run the Java Game: javac Main.java TicTacToe.java java Main
-
Open the Web Interface: Open
index.htmlin your web browser to start playing.
- Players take turns selecting grid positions to place their symbols (X or O).
- The first player to form a horizontal, vertical, or diagonal line wins.
- If the grid is filled without a winner, the game ends in a draw.
Contributions are welcome! Feel free to open issues or submit pull requests for improvements, bug fixes, or new features.