from funtools import reduce
def add(num1,num2):
return num1+num2
a = reduce(add,range(101))
print(a)
reduce
最新推荐文章于 2020-05-19 14:28:21 发布
from funtools import reduce
def add(num1,num2):
return num1+num2
a = reduce(add,range(101))
print(a)