+ 1
How could I write a python to calculate the sum from 1 to 10?
Print y=answer
3 Answers
+ 7
Why not try it yourself? Iif you get stuck post your code so we can help.
(Hint: use a for loop)
+ 3
sum=0
for i in range(1,11):
sum+=i
print(sum)
hope this helps :)
0
print(sum(range(11)))