Created
September 18, 2014 17:03
-
-
Save utinajerolps/b08cda9e00e0fd66890f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Employee(object): | |
"""Models real-life employees!""" | |
def __init__(self, employee_name): | |
self.employee_name = employee_name | |
def calculate_wage(self, hours): | |
self.hours = hours | |
return hours * 20.00 | |
# Add your code below! | |
class PartTimeEmployee(Employee): | |
def calculate_wage(self, hours): | |
self.hours = hours | |
return hours * 12.00 | |
def full_time_wage(self, hours): | |
return super(PartTimeEmployee, self).calculate_wage(hours) | |
milton = PartTimeEmployee("Ulysses") | |
print milton.full_time_wage(10) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment