摘要:
# class Foo:# __N=1# def __init__(self,x,y):# self.x=x# self.__y=y## def __f1(self):# print('f1')## def f2(self):# print(self.__N,self.__y)# print(Foo 阅读全文
摘要:
'''多态:同一种事物的多种形态'''# import abc# class Animal(metaclass=abc.ABCMeta):# @abc.abstractmethod# def speak(self):# pass# class Pig(Animal):# def speak(self 阅读全文