14. This looks like a job for


#1

https://www.codecademy.com/courses/python-intermediate-en-WL8e4/2/4?curriculum_id=4f89dab3d788890003000096#

I've been looking at this code for ages and I can't see what's wrong with it? Can somebody help?

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
        print hours * 12.00
        return hours * 12.00
    def full_time_wage(self,hours):
        return super((PartTimeEmployee, self).calculate_wage()
milton = PartTimeEmployee("aa")
print milton.full_time_wage()

This is my error:

File "python", line 18
milton = PartTimeEmployee("aa")
^
SyntaxError: invalid syntax


#2

look at the line above, the number of opening parentheses (() doesn't match the amount of closing parentheses ()), aka super() is missing the closing parentheses.


#3

Thank you, but now I have the following error:

Traceback (most recent call last):
File "python", line 19, in
TypeError: full_time_wage() takes exactly 2 arguments (1 given)


#4

full_time_wage should have an argument when called, since it has a parameter (hours) look for the required argument value in the last step of the instructions


#5

I'm sorry, I don't understand?


#6

your full time wage method:

def full_time_wage(self,hours):

has a parameter(hours), so when you call your method:

print milton.full_time_wage(//missing argument)

you need an argument (to satisfy the hours parameter). Look in the instructions for the required value for argument


#7

Okay I get it now, thank you :slight_smile:


#8