标签:循环 for python print loop ati ... opera ***
1.for loop
**********
>>> sum=0
>>> for x in [1,2,3,4,5,6,7,8,9,10]:
sum=sum+x
>>> print(sum)
**********
**********
sum=0
for x in range (101):
sum=sum+x
print(sum)
********
运用循环求和( sum operation in python)
标签:循环 for python print loop ati ... opera ***
原文地址:https://www.cnblogs.com/code-saturne/p/10390225.html