Question: please solve asap (java program) Class Diagrams Person String name; private int age; +Person(String n, int al +Person +RetARed +static void sayHi SOP Hi from

please solve asap (java program)  please solve asap (java program) Class Diagrams Person String name; private
int age; +Person(String n, int al +Person +RetARed +static void sayHi SOP

Class Diagrams Person String name; private int age; +Person(String n, int al +Person +RetARed +static void sayHi SOP "Hi from Person"); } Benefit Student Faculty private double salary; double pa +double getSalary: private String id; +Student(String n, int a double s. Stringi) +Student Students) + Studento +Betpal + int getBenefits() { return 20; Benefit VisitingFaculty Exchange +int BetBenefits(){ return 100;} Senior String capstone; RetCapstone static void sayHIO SOP("Hi from Senior"); + int getBenefits() { return super.getBenefits):30); Benefits Interface has one method: int getBenefits(); A-f=> 1 mark each A) The Student class must have an import statement. B) If I make an object of type Exchange, then a constructor in Benefits will be called C)The VisitingFaculty class has a compiler error (analyze what the constructor/super does) E) The Senior class has a compiler error (analyze what the constructor/super does) F) How many instance variables does the Exchange class have, and which ones can it access directly. G) Write only the first and second constructors for the Student class (not the 34 one) (2 marks each)

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!