看板 Python 關於我們 聯絡資訊
※ 引述《huge (huge)》之銘言: : 另外有一個部份小弟沒看懂的是底下這句話 : 如果是因為多重繼承,記得最上層父類別裡的 clear() 要呼叫 super(...).clear() : 保證每一個子類別的 clear() 都會被呼叫到 : 是指說在 parent 裡面藉由呼叫 super().clear() 去執行所有 child 的 clear() 嗎? 這部分請自行閱讀: http://www.cafepy.com/article/python_attributes_and_methods/python_attributes_and_methods.html#id404413 (短網址:http://tinyurl.com/ydkcla3) http://www.python.org/download/releases/2.3/mro/ -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 218.173.129.238
huge:感激 :D 10/08 23:52