# sethsolves/gcpa-calculator architecture

> Architecture diagram of the GitHub repository sethsolves/gcpa-calculator, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sethsolves/gcpa-calculator
- Repository: https://github.com/sethsolves/gcpa-calculator

## Overview

This is a small interactive C++ CGPA/GPA calculator. A student enters a name and five courses; the program computes weighted grade points and total credits, then displays GPA. The README describes broader CGPA and per-course grade reporting, but the shown implementation outputs only GPA. The map reflects the single source file; it does not show file I/O or separate calculation modules.

Main entry points: [`gcpa_calculator.cpp`](https://github.com/sethsolves/gcpa-calculator/blob/main/gcpa_calculator.cpp) (Interactive Calculator)

## Diagram (Mermaid)

```mermaid
flowchart TD

node_student(("Student"))
node_calculator["Interactive Calculator"]
node_course_records[("Course Records")]
node_gpa_calculation["GPA Calculation"]
node_gpa_output["GPA Output"]

node_student -->|"enters details"| node_calculator
node_calculator -->|"collects five courses"| node_course_records
node_calculator -->|"computes weighted GPA"| node_gpa_calculation
node_gpa_calculation -->|"displays GPA"| node_gpa_output

click node_calculator "https://github.com/sethsolves/gcpa-calculator/blob/main/gcpa_calculator.cpp"
click node_course_records "https://github.com/sethsolves/gcpa-calculator/blob/main/gcpa_calculator.cpp"
click node_gpa_calculation "https://github.com/sethsolves/gcpa-calculator/blob/main/gcpa_calculator.cpp"
click node_gpa_output "https://github.com/sethsolves/gcpa-calculator/blob/main/gcpa_calculator.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_student toneIndigo
class node_calculator,node_gpa_calculation,node_gpa_output toneTeal
class node_course_records toneAmber
```

## Components

### Other components

- **Student**
- [Interactive Calculator](https://github.com/sethsolves/gcpa-calculator/blob/main/gcpa_calculator.cpp): `gcpa_calculator.cpp`
- [Course Records](https://github.com/sethsolves/gcpa-calculator/blob/main/gcpa_calculator.cpp): `gcpa_calculator.cpp`
- [GPA Calculation](https://github.com/sethsolves/gcpa-calculator/blob/main/gcpa_calculator.cpp): `gcpa_calculator.cpp`
- [GPA Output](https://github.com/sethsolves/gcpa-calculator/blob/main/gcpa_calculator.cpp): `gcpa_calculator.cpp`

## Connections

- Student → Interactive Calculator: enters details (evidence: `gcpa_calculator.cpp`)
- Interactive Calculator → Course Records: collects five courses (evidence: `gcpa_calculator.cpp`)
- Interactive Calculator → GPA Calculation: computes weighted GPA (evidence: `gcpa_calculator.cpp`)
- GPA Calculation → GPA Output: displays GPA (evidence: `gcpa_calculator.cpp`)
