Great Deal! Get Instant $10 FREE in Account on First Order + 10% Cashback on Every Order Order Now

Write a program in Java that performs the following tasks: Creates a class called Person having attributes personName, personID. Creates a subclass called Student of Person class having attributes...

1 answer below »

Write a program in Java that performs the following tasks:

  • Creates a class called Person having attributes personName, personID.
  • Creates a subclass called Student of Person class having attributes stdGPA, stdMajor.
  • Creates a subclass called Teacher of Person class having attributes teacherCourse, teacherSalary.
  • Write the constructors for Person, Student and Teacher class to initialize the attributes(fields).
  • Write a method displayDetails() in Student and Teacher class to print all attributes of superclass and subclass.
Answered 14 days After Jun 02, 2022

Solution

Kshitij answered on Jun 17 2022
78 Votes
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here