Python学习笔记(1)

2020-01-16 12:36:12 浏览数 (1)

代码语言:javascript复制
1 def sum_args(*args):
2     return sum(args))
3     
4 def run_with_positional_args(func, *args):
5     return func(*args)
6 
7 run_with_positional_args(sum_args, 1, 2, 3, 4)

0 人点赞