Giter Site home page Giter Site logo

temmarie / tic-tac-toe Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 1.0 37 KB

We built a tic-tac-toe game on the command line where two human players can play against each other and the board is displayed in between turns.

Ruby 100.00%
game characters turns player ruby

tic-tac-toe's Introduction

Tic-Tac-Toe Project

We built a tic-tac-toe game on the command line where two human players can play against each other and the board is displayed in between turns. It was made as a collaborative project in Ruby using OOP concepts.

What it does

The game collects input from the users and replaces the board positions based on the user inputs with their individual characters. To win the game, a player has to have 3 of their characters in a row (vertically, horizontally or diagonally).

Live demo

Tic Tac Toe

Built With

Ruby

Getting Started

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

Clone the project unto your local machine cd to the folder and run bin/main.rb on your terminal

Instructions to Play

  • The game is played on a grid that's 3 squares by 3 squares.

  • Input your name by pressing "P" or join as a guest by pressing "Enter"

  • Player1's character is "X" and Player2's character is "O"

  • Players take turns putting their characters in empty squares.

  • The first player to get 3 of their characters in a row (vertically, horizontally or diagonally) is the winner.

  • When all 9 squares are full, the game is over. If no player has 3 characters in a row, the game ends in a tie.

  • You can restart the game if you wish to!

Prerequisites

  • Get ruby latest version installed

Install

  • Install VSCode or any code editor you like
  • Install Node JS and nmp(most recents versions)

Authors

๐Ÿ‘ค Osong Agberndifor

๐Ÿ‘ค Grace Tamara Ekunola

๐Ÿค Contributing

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

Acknowledgments

Show your support

Give a โญ๏ธ if you like this project!

Enjoy!

tic-tac-toe's People

Contributors

osong-michael avatar temmarie avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Forkers

mariosknl

tic-tac-toe's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.