Question: Overloading: The ExternalContractor class had two overloaded methods: weeklyPay and getHourlyRate. Consider the following: ExternalContractor kim = new ExternalContractor ( Kim , 1
Overloading:
The ExternalContractor class had two overloaded methods: weeklyPay and getHourlyRate.
Consider the following:
ExternalContractor kim new ExternalContractorKim;
kim.weeklyPay;
Consider whether you call Employee's weeklyPay method on a ExternalContractor object? Does overloading a method prevent access to the parent method such as when overriding a method
Group of answer choices
No overloading does not prevent access ot the parent method because the method signatures are different.
Yes, access to the parent method is prevented becuase the method names are the same and you can't use super from the client code.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
