摘要:
python 为何要设计这种?正确:def f(a=2,b=2,c=3): return a+b+cprint(f(*(1,1),c=1))错误:def f(a=2,b=2,c=3): return a+b+cprint(f(*(1,1),1))会被提示:而这个会被提示:def f(a=2,b=2,c=3): return a+b+cprint(f(a=1,*(1,1)))>>> Traceback (most recent call last): File "C:\Users\un_ieval.py", line 91, in print(f(a=1,* 阅读全文