Skip to content

This repository contains a classic console-based Snake game 🐍👨‍💻🎮implemented in C++. The primary purpose of this project is to practice and demonstrate object-oriented programming (OOP) skills as a freshman computer science student. The game offers a fun and interactive way to hone your coding skills while enjoying a nostalgic gaming experience

Notifications You must be signed in to change notification settings

aenon0/Cpp-Snake-Game-OOP-Practice

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Snake Game in C++ (Console App)

A simple console-based Snake game implemented in C++ to practice and demonstrate object-oriented programming (OOP) skills.

Table of Contents

Features

  • Object-oriented design following C++ best practices.
  • A classic Snake game experience in the console.
  • Arrow key controls for direction.
  • Modular code for easy understanding and customization.

Prerequisites

To run the Snake game, you need to have:

  • A C++ compiler (e.g., GCC or MinGW) installed on your system.

Installation

  1. Clone the repository: git clone https://github.com/aenon0/Cpp-Snake-Game-OOP-Practice.git
  2. Compile the code: g++ main.cpp -o SnakeGame
  3. Run the game: ./SnakeGame

How to Play

Use the arrow keys (asdw) to control the direction of the snake. The snake will grow when it eats the food. Avoid running into the walls The game ends when you collide with the walls.

##Contributing

  1. welcome contributions to improve the game or add new features. To contribute, follow these steps: Fork the repository.
  2. Create a new branch for your feature or fix: git checkout -b feature/your-feature-name.
  3. Make your changes and commit them: git commit -m 'Add feature'.
  4. Push to the branch: git push origin feature/your-feature-name.
  5. Create a pull request on GitHub.

About

This repository contains a classic console-based Snake game 🐍👨‍💻🎮implemented in C++. The primary purpose of this project is to practice and demonstrate object-oriented programming (OOP) skills as a freshman computer science student. The game offers a fun and interactive way to hone your coding skills while enjoying a nostalgic gaming experience

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published