0

# sum.py

# tpm

# A program that accepts an indeterminate (any number) of integers entered by

# the user, calculates and their sum, using loop

```
from math import *
def calc_sum():
n = input("Enter any number: ")
sum = 0.0
for i in range(n):
x = input("Enter a number >> ")
sum = sum + x
print "\nThe sum of the numbers is", sum / n
main()
```

:sad: :mad: :confused: :o :( :cry: :evil: