标签: python-3.x
我只是想知道为什么参数不会在以下程序中打印?谢谢
def my_func(param): param = param.append(4) print(param) #prints none return param mylist = [1, 2, 3] newlist = my_func(mylist) print(mylist, newlist) #prints [1,2,3,4] none