Python基础学习代码之面向对象编程【点击查看详情】
Python基础学习代码之面向对象编程:class AddrBookEntry(object): 'address book entry class' def __init__(self,nm,ph): self.name = nm self.phone = ph print 'created instance for:',self.name def updatephone(self,newph): self.phone = newph print 'update phone