怎么不对呢
class Person(object):
def __init__(self, name, score):
self.name = name
#self.score = score
self.__score = score
p = Person('Bob', 59)
print p.name
print p.__score
class Person(object):
def __init__(self, name, score):
self.name = name
#self.score = score
self.__score = score
p = Person('Bob', 59)
print p.name
print p.__score
2017-12-07
举报