Skip to content

๐ŸŽฎ Fun Math Game in C++ โž—โœ–๏ธโž•โž– Challenge yourself with math problems, track your score, and level up! ๐Ÿ†

Notifications You must be signed in to change notification settings

taharachedi/Math-Game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

7 Commits
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿงฎ Math Quiz Game in C++ ๐ŸŽฎ

A fun and interactive console-based quiz game where players solve math problems in multiple levels! ๐ŸŒŸ


๐ŸŒŸ Project Overview

This C++ project simulates a Math Quiz game ๐Ÿง , where players answer questions with different difficulty levels (Easy, Medium, Hard, and Mixed). Players can choose the number of questions and the type of mathematical operation (Addition, Subtraction, Multiplication, Division, or Mixed). The game checks the answers and provides real-time feedback. Players are given the option to replay the game.


โœจ Features

  • ๐Ÿง  Multiple Difficulty Levels: Choose from Easy, Medium, Hard, or Mixed levels.
  • โž• Various Operations: Add, subtract, multiply, divide, or a mix of them!
  • ๐Ÿ“Š Real-Time Feedback: Instant response to answers, with correct and incorrect indications.
  • ๐ŸŽจ Dynamic Console Colors: Green for correct answers, Red for wrong ones.
  • ๐Ÿ† Final Score Summary: A final report of correct and wrong answers, showing whether the player passed or failed.
  • ๐Ÿ” Replay Option: Play as many games as you want with a replay prompt.
  • ๐Ÿค– Randomized Questions: The game generates random numbers for each question, ensuring unique quizzes every time.

โš™๏ธ How It Works

Core Components

  1. Player Input:

    • The player selects the number of questions, difficulty level, and operation type.
    • The player answers math questions, which vary based on difficulty and operation type.
  2. Question Generation:

    • Random Numbers: Each question consists of two numbers chosen randomly within specific ranges based on the difficulty.
    • Operations: The program can generate addition, subtraction, multiplication, division, or random combinations.
  3. Answer Checking:

    • After the player answers, the program checks the correctness of the answer.
    • Results are displayed immediately with color feedback (Green for correct, Red for wrong).
  4. Scoring and Summary:

    • The total number of correct and wrong answers are tracked.
    • The playerโ€™s result is displayed as either "PASS" or "FAIL" based on the number of correct answers.

๐ŸŽฏ Learning Outcomes

This project helps you explore and implement various C++ programming concepts:

  • โœ… Enums and Structs: Organizing game elements efficiently.
  • โœ… Functions: Ensuring modularity and reusability for game logic.
  • โœ… Random Number Generation: Adding unpredictability to gameplay.
  • โœ… Control Structures: Utilizing loops and conditionals for decision-making.
  • โœ… Console Formatting: Using colors and formatted output to enhance interactivity.

๐Ÿ Ready to Play?

Clone this repository, compile the code, and start challenging the computer!๐Ÿš€

About

๐ŸŽฎ Fun Math Game in C++ โž—โœ–๏ธโž•โž– Challenge yourself with math problems, track your score, and level up! ๐Ÿ†

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages