摘要: class ClassName: __privt = 50 # 私有变量 a = ClassName() # 私有变量外界无法访问 print(a.__privt) # AttributeError: 'ClassName' object has no attribute '__privt' pri 阅读全文
posted @ 2023-12-13 23:13 sangern 阅读(6) 评论(0) 推荐(0) 编辑