Skip to content

pyagnik1/tic-tac-toe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Part I

Tic Tac Toe is a very popular game played by many children all over the world. You will re-create this game using your knowledge of arrays, methods and loops. Here are the program specifications:

Build a 1-player game: the player against the computer. Find a resource online that explains how the game is played. This will be your documentation. Include the URL of your documentation in a comment. Use a two-dimensional array to represent the game board. Use a nested for loop to initialize the multi-dimensional array with some neutral value (a dash is a sensible choice). Include comments to clarify any code whose purpose is not obvious You must have a separate method to do each of the following:

Initialize the board (use a nested for loop) Print the game board to the console Input the player's move Determine the computer's random move (the computer doesn't need to play intelligently, just legally) Determine a winner diagonally Determine a winner horizontally Determine a winner vertically Feel free to create additional methods as needed!

. alt text

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages