0
這Python代碼Python的瓦爾()在科特林
class Test:
def __init__(self):
self.one = "python"
self.two = "is"
self.three = "fun!"
t=Test()
print(vars(t))
打印字段及其值的集合: {'one': 'python', 'two': 'is', 'three': 'fun!'}
我怎樣才能做到在科特林一樣嗎?