Skip to content

Div685/rspec_TicTacToe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tic-Tac-Toe

img

issues Licence pull request

About the Project

This Project is about Building Tic-tac-toe game using OOP concept of Ruby. Tic-Tac-Toe game is paper-pen game which requires two players to play game Player1 can be 'X' and player2 can be 'O'. It uses 3X3 grids which has 9 moves for both players to complete the Game. Any one of the player can win the game if he/she has got all 'X' or 'O' in any one of the possible position i.e first Row, Middle Row, last Row, First Column, Middle Column, last column, left Diagonal and Right Diagonal. This project requires to complete the following milestones:

  • OOP-Milestone: Setup
  • OOP-Milestone: User interface
  • OOP-Milestone: Game logic
  • OOP-Milestone: instruction for player

Table of Contents

Built With

Live Demo

Live Demo Link

Getting Started

To get a local copy up and running follow these simple example steps.

  1. If you're running the Windows Operating System, open your command prompt. On Linux, Open your terminal.

  2. Copy and paste the following code into the Terminal:

    git clone https://github.com/IjayAbby/Tic-Tac-Toe.git

  3. Press Enter.

  4. Once the repository has been cloned, navigate inside the repository and type: bin/main This will run the game and you will be able to play it using the terminal.

  5. Enjoy

Game Instructions

Tic-Tac-Toe is a very popular game, which consists in making a sequence of three symbols in either a row, column or diagonal in a 3x3 board. To play the game follow the getting started steps mentioned above this file. After you done that, run the main file and follow these steps:

  • The game displays the board with the a welcome note on top.
  • You will be prompted as a first player to enter your preferred name.
  • You will be prompted as a second player to enter your preferred name.
  • You will be prompted to choose who should go first.
  • You will be provided with the choices you can pick from that is, between 1 - 9.
  • You will play in turns, in sequence till the board is full then it will announce the game results ie, draw or winner.
  • If you want to play again you can say (Y) yes or entirely quit the game by choosing (N).

To test the code with rspec.

  • install rspec using gem install rspec
  • run rspec or rspec --format doc on your terminal to test the code .

Contributing

Contributions, issues, and feature requests are welcome! Feel free to check the issues page.

Show your support

Give a ⭐️ if you like this project!

License

This project is MIT licensed.

Authors

👤 Divyesh Patel

👤 Dipesh Bajgain

👤 Ijay Abby

Acknowledgments

About

Tic-Tac-Toe game built using OOP concept of Ruby.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages