今天在练习python类的第一个代码的时候运行代码报错如下:
Traceback (most recent call last):
File "D:/code/test.py", line 10, in <module>
bart = Student('Bart Simpson', 59)
TypeError: Student() takes no arguments
后来发现把“__init__”写成“__int__”了,好尴尬
在此记录一下,啊哈哈哈
原文地址:https://blog.youkuaiyun.com/xuantaiyang888/article/details/81035885