Question: in java program The following classes and inheritance hierarchy are used to store the information of people attending a conference: Person name: String type intr-Presenter,

in java program
in java program The following classes and inheritance hierarchy are used to
store the information of people attending a conference: Person name: String type

The following classes and inheritance hierarchy are used to store the information of people attending a conference: Person name: String type intr-Presenter, 2-Participant - Person(String, int setPerson/String Int vold getName: String .getType: Int .toString: String Citizen NonCitizen IN Sting passport No String -NonCanzon(Sting. me. Stingle - Cinzentrieg Int. String Setizen String, int String: vold getico Swing - String: Sting GaicFeel: double - selfonien(String, int Strings vold - getPassporto: String - ToString Sering - calcFeed double Tasks: I a) Define all classes above. b) Write the definition of method calcFee () for both subclasses. The methods determine the fee to be paid by a person using the following table: Fee (RM) Person Presenter Participant Citizen 1272.00 795.00 Non Citizen 1484.00 900.00 c) Write a driver program to test your inheritance classes. 1) Declare an array of object, cList to store data on Citizen objects. The size of the array is determined by the user. ii) Calculate and display the total fees collected from the participants. iii) Display the list of presenters (name) for those who from Johor

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!