本文共 116 字,大约阅读时间需要 1 分钟。
今天写python的构造函数
遇到了第一个问题
——————TypeError: this constructor takes no arguments
百度之后,原来是因为_init_
正确的做法是前后都是双下划线__init__
转载地址:http://rwjqb.baihongyu.com/