I need to declare a class called Grade. A grade will be consisting scores from 1
ID: 3658678 • Letter: I
Question
I need to declare a class called Grade. A grade will be consisting scores from 1 to 100, and a grade A,B,C,D,F, and a name.
Write a default and a parameterized constructor for this class.
Write a set method for this class to set all fields.
Write a print method to print the fields.
The grade should be found from the following: 90 and above = A, 80-89 = B, 70-79 = C, 60-69=D, less than 60 F.
Write a driver that creates an array of 5 Grade objects. In the driver call a function that prints all scores that are greater than 80.
consider the following code:
struct ListNode
{
char value;
struct ListNode *next;
};
ListNode *head;
Explanation / Answer
class grade { int a; grade() { a=0; } grade(int x) { a=x; } void print() { if(a>=90) coutRelated Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.