A simple Java console program that calculates and displays the grades and averages of multiple students across several subjects, including the class average and the top-performing student.
- Uses arrays and loops to store and process grades.
- Displays individual student averages.
- Computes the class average.
- Identifies the top student with the highest average.
- Adds colorful terminal output using ANSI escape codes.
Language: Java
Author: Carlo Sebastian M. Dingle
Subject Example: CCINCOML, CCPRGG1L, CCPRGG2L
School: National University - MOA
- Save the file as
StudentGrades.java. - Open the directory in VS Code or any Java IDE.
- Compile the program using:
javac StudentGrades.java
- Run the compiled program:
java StudentGrades
=========================================
NATIONAL UNIVERSITY - MOA GRADE REPORT
=========================================
Enter grades for Donasco:
CCINCOML: 85
CCPRGG1L: 90
CCPRGG2L: 88
...
=========================================
STUDENT GRADE REPORT
=========================================
Name CCINCOML CCPRGG1L CCPRGG2L Average
---------------------------------------------------
Donasco 85 90 88 87.67
Dingle 92 89 95 92.00
Cachapero 80 85 82 82.33
---------------------------------------------------
Class Average: 87.33
Highest Average: Dingle (92.00)
This project is open source and available under the MIT License.