How baraaelgendy/gpa-calculator works
This is a console GPA calculator for recording semester courses, calculating GPA or cumulative GPA, and viewing saved student results. The main menu dispatches to calculation, name-search, or all-history screens. Calculation screens collect validated input and use the student/course model to calculate grades and averages; each result is appended to History.txt. Search and history screens reload that file and present matching records or report cards. The sampled code supports the flow and persistence details; no README description or unsampled implementation details are available.
Main entry points: clsStudent.h Student model · clsMainMenuUI.h Main menu · clsCalcGPAScreen.h GPA screen · clsCalcCGPAScreen.h CGPA screen
Components 13
Console interface
- Main menu
clsMainMenuUI.h - GPA screen
clsCalcGPAScreen.h - CGPA screen
clsCalcCGPAScreen.h - Find results
clsFindStudentResults.h - History screen
clsShowAllHistoryScreen.h - Application entry
GPA Calculator.cpp
Calculation
- Student model
clsStudent.h - Course grading
clsCourse.h
Student records
- Calculation history
History.txt
Shared utilities
- Input validation
clsInputValidate.h - String utilities
clsString.h - Date and time
clsDate.h
Other components
- Console user
Connections 24
- Console user → Application entry: starts
- Application entry → Main menu: opens
- Console user → Main menu: chooses
- Main menu → Input validation: validates choice
- Main menu → GPA screen: dispatches
- Main menu → CGPA screen: dispatches
- Main menu → Find results: dispatches
- Main menu → History screen: dispatches
- GPA screen → Input validation: validates input
- CGPA screen → Input validation: validates input
- GPA screen → Student model: creates and calculates
- CGPA screen → Student model: creates and calculates
- Student model → Course grading: adds courses
- GPA screen → Student model: saves result
- CGPA screen → Student model: saves result
- Student model → Calculation history: appends records
- Student model → Date and time: gets timestamp
- Student model → String utilities: parses records
- Find results → Input validation: reads search input
- Find results → Student model: loads records
- History screen → Student model: loads records
- Student model → Calculation history: reads records
- Find results → String utilities: matches names
- History screen → Student model: renders records