# abdullahgemoli-svg/math-quiz-system architecture

> Architecture diagram of the GitHub repository abdullahgemoli-svg/math-quiz-system, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/abdullahgemoli-svg/math-quiz-system
- Repository: https://github.com/abdullahgemoli-svg/math-quiz-system

## Overview

This is a single-file C++ console math quiz. The principal workflow is replay setup, quiz configuration, randomized question generation, answer collection and scoring, then a pass/fail summary. The graph separates those domain stages and the calculation/rendering helpers they invoke. All runtime behavior is in the one sampled source file; there is no README content or evidence for additional product subsystems.

Main entry points: [`Final Term Project.cpp`](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp) (Run quiz)

## Diagram (Mermaid)

```mermaid
flowchart TD

node_player(("Player"))
node_console["Console"]
node_main["Program entry"]
node_replay["Replay loop"]
node_reset["Screen reset"]
node_play["Run quiz"]
node_config["Quiz setup"]
node_generate["Question generation"]
node_question["Question generator"]
node_random["Random selection"]
node_calculator["Arithmetic"]
node_answer_loop["Answer round"]
node_render["Question display"]
node_answer_input["Answer input"]
node_grading["Answer grading"]
node_results["Quiz summary"]
node_format["Display formatting"]

node_player -->|"enters choices"| node_console
node_console -->|"reads replay"| node_replay
node_main -->|"starts"| node_replay
node_replay -->|"resets screen"| node_reset
node_replay -->|"starts quiz"| node_play
node_play -->|"reads settings"| node_config
node_config -->|"prompts and reads"| node_console
node_play -->|"creates questions"| node_generate
node_generate -->|"generates each"| node_question
node_question -->|"selects values"| node_random
node_question -->|"computes answer"| node_calculator
node_play -->|"runs rounds"| node_answer_loop
node_answer_loop -->|"displays question"| node_render
node_answer_loop -->|"reads response"| node_answer_input
node_answer_input -->|"reads input"| node_console
node_answer_loop -->|"checks response"| node_grading
node_grading -->|"prints feedback"| node_console
node_grading -->|"sets feedback color"| node_format
node_render -->|"formats labels"| node_format
node_render -->|"prints question"| node_console
node_play -->|"prints summary"| node_results
node_results -->|"formats result"| node_format
node_results -->|"prints summary"| node_console

click node_main "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_replay "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_reset "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_play "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_config "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_generate "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_question "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_random "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_calculator "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_answer_loop "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_render "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_answer_input "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_grading "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_results "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"
click node_format "https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_player,node_console toneIndigo
class node_main,node_replay,node_play,node_config,node_generate,node_question,node_random,node_calculator,node_answer_loop,node_render,node_answer_input,node_grading,node_results,node_format toneTeal
class node_reset toneBlue
```

## Components

### Other components

- **Player**
- **Console**
- [Program entry](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Replay loop](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Screen reset](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Run quiz](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Quiz setup](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Question generation](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Question generator](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Random selection](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Arithmetic](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Answer round](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Question display](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Answer input](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Answer grading](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Quiz summary](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`
- [Display formatting](https://github.com/abdullahgemoli-svg/math-quiz-system/blob/main/Final%20Term%20Project.cpp): `Final Term Project.cpp`

## Connections

- Player → Console: enters choices
- Console → Replay loop: reads replay
- Program entry → Replay loop: starts
- Replay loop → Screen reset: resets screen
- Replay loop → Run quiz: starts quiz
- Run quiz → Quiz setup: reads settings
- Quiz setup → Console: prompts and reads
- Run quiz → Question generation: creates questions
- Question generation → Question generator: generates each
- Question generator → Random selection: selects values
- Question generator → Arithmetic: computes answer
- Run quiz → Answer round: runs rounds
- Answer round → Question display: displays question
- Answer round → Answer input: reads response
- Answer input → Console: reads input
- Answer round → Answer grading: checks response
- Answer grading → Console: prints feedback
- Answer grading → Display formatting: sets feedback color
- Question display → Display formatting: formats labels
- Question display → Console: prints question
- Run quiz → Quiz summary: prints summary
- Quiz summary → Display formatting: formats result
- Quiz summary → Console: prints summary
