Title: Update GradeTracker.py by ZohaiAli · Pull Request #7 · dominict/pythonteachingcode · GitHub
Open Graph Title: Update GradeTracker.py by ZohaiAli · Pull Request #7 · dominict/pythonteachingcode
X Title: Update GradeTracker.py by ZohaiAli · Pull Request #7 · dominict/pythonteachingcode
Description: Summary This update improves the structure and readability of the grade tracking program. The goal was to make the code cleaner, more modular, and more reliable while keeping all original functionality intact. Changes Made Refactored functions for clarity and maintainability Added input validation to prevent crashes from invalid or non-numeric grades Improved menu flow and error handling Added confirmation step when removing a student Enhanced print/output formatting for better user experience Simplified main loop to avoid repetitive code Why This Matters The previous version worked but was difficult to maintain, lacked validation, and mixed logic with user I/O. This refactor keeps the same behavior but improves code quality and usability, making future changes safer and faster. Testing All main features (add, remove, average) tested manually in terminal Invalid input cases tested (non-numeric grades, unknown students, etc.) Verified no regressions or broken functionality Next Steps (optional) Add file-based persistence (save/load student data) Add a feature to register new students interactively Possibly include basic unit tests for main functions
Open Graph Description: Summary This update improves the structure and readability of the grade tracking program. The goal was to make the code cleaner, more modular, and more reliable while keeping all original function...
X Description: Summary This update improves the structure and readability of the grade tracking program. The goal was to make the code cleaner, more modular, and more reliable while keeping all original function...
Opengraph URL: https://github.com/dominict/pythonteachingcode/pull/7
X: @github
Domain: patch-diff.githubusercontent.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:d7f8f9d2-6031-d90d-0349-d2103fb8af25 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | A4A6:B8F11:2719C1:34058E:698F7062 |
| html-safe-nonce | eddc30a6ba63568f7b5ed8b04898898df351c28ff46b64602bc21ffc4bd9bfae |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBNEE2OkI4RjExOjI3MTlDMTozNDA1OEU6Njk4RjcwNjIiLCJ2aXNpdG9yX2lkIjoiMzI2OTQ4MTg4ODA2Mjg2MTQxMCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | fe211c01a7c2bbf697d86874d1550091bb0d0e4adb4d6dc62490efc7985cf6e4 |
| hovercard-subject-tag | pull_request:2957929790 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/dominict/pythonteachingcode/pull/7/files |
| twitter:image | https://avatars.githubusercontent.com/u/95756200?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/95756200?s=400&v=4 |
| og:image:alt | Summary This update improves the structure and readability of the grade tracking program. The goal was to make the code cleaner, more modular, and more reliable while keeping all original function... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 7ab1c9acb90dba91d5e994ebfb6bfb1130e0e0e6aca329cdbbd934d636e22ab6 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/dominict/pythonteachingcode git https://github.com/dominict/pythonteachingcode.git |
| octolytics-dimension-user_id | 835490 |
| octolytics-dimension-user_login | dominict |
| octolytics-dimension-repository_id | 188240666 |
| octolytics-dimension-repository_nwo | dominict/pythonteachingcode |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 188240666 |
| octolytics-dimension-repository_network_root_nwo | dominict/pythonteachingcode |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 1d6695367a1b2f05addc4030b791720f01693df4 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width