以这种方式从函数返回多个值是pythonic吗?
def f(): f.x = 1 f.y = 2 return f r = f() print r.x,r.y 1 2
python
python ×1