print(sum(range(10)))的结果是( )
举一反三
- 如下程序的运行结果是?sum=0 for i in range(2,101,2): sum=sum+i print(sum)
- 下面代码的输出结果是 sum = 1.0 for num in range(1,4): sum+=num print(sum)
- 下列程序的输出结果是:sum = 0 def sum(i1, i2): result = 0 for i in range(i1, i2 + 1): result += i return result print sum(1, 10)
- 下面代码的输出结果是()。 sum<br/>= 0<br/>for<br/>i in range(0,11): sum<br/>+= i print() A: 55 B: 66 C: 10 D: 11
- def func(): global sum sum=0 print(sum) for i in range(5): sum+=1 print(sum) func() print(sum)