Question: Add an abstract class called Person to your project Add the following public properties to your Person class: (String) name (int) age Add another class

Add an abstract class called Person to your project

Add the following public properties to your Person class:

(String) name

(int) age

Add another class called Employee that inherits from Person and add the following public properties:

(double) salary

(int) yearsOfService

Add another class called Student that inherits from Person and add the following public properties:

(ArrayList) grades

(int) yearInSchool

(String) major

In the Student class create a method called getAverage() that will cycle through all grades in the array list and return the average. Note: if you want to know the number of elements in an array list it is: grades.size() This is equivalent to an arrays .length

Add another class of your choosing and include appropriate properties to the class

For all classes include:

A single workhorse constructor

toString() method

can someone tell me how to do this one?I totally have no idea.....

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!