执行给定Python程序后的输出结果是
执行下列Python程序,最后的输出是()?
lst = [1, 2, 7, 10, 15, 17, 22]
result = d = 3
for i in range(1, len(lst)):
if lst[i] - lst[i - 1] > d:
result += d
else:
result += lst[i] - lst[i - 1]
print(result)
正在加载题目数据…
子题
该题型需在试卷/作业中作答,单题练习暂不支持
答案解析