Question: Write a Python class definition UnionMember which is a subclass of Employee and has attributes as follows: hourly pay rate number of hours worked whether

Write a Python class definition UnionMember which is a subclass of Employee and has attributes as follows: hourly pay rate number of hours worked whether the member is a full-time worker or part-time worker (F for full-time, 'P' for part-time) Define the following methods: a constructor which takes employee name, date of hire, hourly rate of pay, number of hours worked and whether or not the member is a full-time worker, and initializes the corresponding attributes. a method called calcPay to compute and return the pay for a UnionMember object calculated as follows if the member is a full-time worker, then the pay is number of hours worked multiplied by the hourly rate if the member is not a full-time worker, the pay rate is 75% of the hourly rate of pay a_repr_method which returns a string of all information about a UnionMember Write a Python class definition UnionMember which is a subclass of Employee and has attributes as follows: hourly pay rate number of hours worked whether the member is a full-time worker or part-time worker (F for full-time, 'P' for part-time) Define the following methods: a constructor which takes employee name, date of hire, hourly rate of pay, number of hours worked and whether or not the member is a full-time worker, and initializes the corresponding attributes. a method called calcPay to compute and return the pay for a UnionMember object calculated as follows if the member is a full-time worker, then the pay is number of hours worked multiplied by the hourly rate if the member is not a full-time worker, the pay rate is 75% of the hourly rate of pay a_repr_method which returns a string of all information about a UnionMember
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
