Question: java code please ans ignore part 2 of the question thank you Lab 3 - Small Inheritance Assignments This lab is to give you some
Lab 3 - Small Inheritance Assignments This lab is to give you some experience writing classes using inheritance. We're not quite in a situation in which you can write a giant program...yet. We'll get there! This will involve some writing below, and some questions from the text. Here is the assignment: 1) Create a UEmployee class that contains member variables for the university employee name and salary. The Employee class should contain member methods for returning the employee name and salary. Create Faculty and Staff classes that inherit the Employee class. The Faculty class should include members for storing and returning the department name. The staff class should include members for storing and returning the job title. Write a runner program that creates one instance of each class and prints all of the data for each object. 2) Complete Programming Challenges 7 and 8 on page 698 of the textbook (Person, Customer and Preferred Customer classes). Chapter 10 As always, comment your code! This is due by Wednesday, March 10 at the end of class! Note: For Preferred Customer, add a public void method named make Purchase, which has one double value as its parameter. Is function is to add the parameter to the internal amount spent variable for the Preferred Customer, and it will need to update the discount if this Preferred Customer has reached a new rewards tier. Make sure your runner makes purchases that changes, and displays new discounts for Preferred Customers
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
