- 博客(1)
- 资源 (1)
- 收藏
- 关注
原创 Python中的super()用法
如果在子类中也定义了_init_()函数,那么该如何调用基类的_init_()函数:方法一、明确指定 :class C(P): def __init__(self): P.__init__(self) print 'calling Cs construtor'方法二、使用super()方法 :class C(P...
2018-08-06 18:30:08 72720 4
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人