Python函数参数中的None与默认值
def foo1(x, item=[]): item.append(x) return itemdef foo2(x, item=None): if item is None: item = [] item.append(x) return itemprint(foo1(1))print(foo2(2))item = []p...