python面向对象课程中如下代码本地运行后报错,求解
class Programer(object): hobby='Play Computer' def __init__(self, name, age, weight): self.name = name self._age = age self.__weight = weight @classmethod def get_hobby(cls): return cls.hobby @property def get_weight(self): return self.__weight def self_introduction(self): print ('My name is %s \nI an %s years old\n' %(self.name, self.age)) class BackendProgramer(Programer): def __int__(self, name, age, weight, language): super(BackendProgramer, self).__int__(name, age, weight) self.language = language if __name__ == '__main__': programer = BackendProgramer.('Albert', 25, 80, 'Python') print (dir(programer)) print (programer.__dir__) print (type(programer)) print (isinstance(programer, Programer))
报错信息如下:
Traceback (most recent call last):
File "C:/Users/WMY/Documents/python study/2017-2-12.py", line 26, in <module>
programer = BackendProgramer('Albert', 25, 80, 'Python')
TypeError: __init__() takes 4 positional arguments but 5 were given
不懂啥意思,只有4个参数呀,求解?