【python学习笔记】Python中*args 和**kwargs的用法

说明 python中默认缺省参数,参数名传参,可变长度传参。python 缺省参数 def foo(a,b=8): print a,b foo("leason") #leason 0 foo("leason",88) #def 88 参数名传参数 def foo(a,b): print a,b foo("hello",'world') # helloworld foo(b=
相关文章
相关标签/搜索