Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- total = 0
- opFile = open('textfile.txt', 'r')
- for line in opFile:
- num = float(line)
- total += num
- print(total)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement