E
Eric Wolfe
I need some guidance getting started on this project:
----------------------
Implement a class Employee as follows:
Constructor: An object of class Employee will have the hourlyRate as
an instance field.
Methods
o basePay(int hours): Calculates the amount paid for the first 40
hours.
o extraPay(int hours): Calculates the amount paid for all the hours
worked after the first 40 hours. The pay for extra hours is double the
pay for regular hours.
o totalPay(int hours): Calculates the total pay.
Write a short tester program that allows the user to input any
employee to print the total pay. Make sure when you test your file to
enter employees that have worked:
- less than 40 hours
- exactly 40 hours
- more than 40 hours
----------------------
Implement a class Employee as follows:
Constructor: An object of class Employee will have the hourlyRate as
an instance field.
Methods
o basePay(int hours): Calculates the amount paid for the first 40
hours.
o extraPay(int hours): Calculates the amount paid for all the hours
worked after the first 40 hours. The pay for extra hours is double the
pay for regular hours.
o totalPay(int hours): Calculates the total pay.
Write a short tester program that allows the user to input any
employee to print the total pay. Make sure when you test your file to
enter employees that have worked:
- less than 40 hours
- exactly 40 hours
- more than 40 hours