class attrdict(dict): def __init__(self, *args, **kwargs): dict.__init__(self, *args, **kwargs) self.__dict__ = selfa = attrdict(x=1, y=2)print a.x, a.yb = attrdict()b.x, b.y
在线咨询:
邮箱: xwei067@foxmail.com
工作时间:周一至周五,9:00-17:30,节假日休息