Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Your GradeChanger class will enable the user to replace a student's given grade in a course with a new one, to add a new course

Your GradeChanger class will enable the user to replace a student's given grade in a course with a new one, to add a new course grade, and to compute the GPA.

Your class will have

1.two private instance variables that store the total credits earned in all courses (an int) and the total grade points earned (a double)

2.A constructor with two parameters - total credits and GPA - which will be used to initialize the instance variables

F total grade points is not a construction parameter; GPA is.Your constructor will initialize total grade points to GPA x total credits

3.An accessor ("get") method that returns the total credits

4.An accessor ("get") method that returns the total grade points

5.A mutator ("set") method that adds the grade for a new course. This method will have 2 parameters - the number of credits and the numeric grade earned

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Financial management theory and practice

Authors: Eugene F. Brigham and Michael C. Ehrhardt

12th Edition

978-0030243998, 30243998, 324422695, 978-0324422696

Students also viewed these Programming questions