Skip to content

Latest commit

 

History

History
23 lines (15 loc) · 1.13 KB

README.md

File metadata and controls

23 lines (15 loc) · 1.13 KB

Snake Game in C++

Description

This repository contains the source code for a classic Snake game implemented in C++ as a university project. Due to the project's scope and requirements, the code is contained within a single file, and the comments are in Spanish to meet the project's guidelines.

The game features a snake represented by characters, and the player controls the snake to eat food, growing in length with each consumed food. The objective is to achieve the highest score possible by avoiding collisions with the walls or the snake's own body.

Features

  • Simple and intuitive console-based user interface
  • Real-time control of the snake's movement using arrow keys (Up, Down, Left, Right)
  • Randomly generated food for the snake to eat
  • Score tracking and display
  • Game over detection when the snake collides with the wall or its own body

How to Play

  • Use the arrow keys (Up, Down, Left, Right) to control the snake's movement
  • Try to eat the food ('*') to grow in length and score points
  • Avoid hitting the walls or colliding with the snake's own body, as this will result in game over

Have fun playing the Snake Game!