现有如下Python代码,运行后输出的结果是?
from functools import reduce
def add(x, y):
return x + y
lst = [1, 2, 3, 4, 5]
res1 = list(map(lambda x: x * 2, filter(lambda x: x % 2 == 0, lst)))
res2 = reduce(add, lst)
print(res1, res2)
正在加载题目数据…
子题
该题型需在试卷/作业中作答,单题练习暂不支持
答案解析