Skip to main content
1 of 3
MTHL
  • 535
  • 1
  • 5
  • 6

Euler_Project #1 Multiples of 3 and 5

Python 2.7

[![Question][1]][1] Question link: https://projecteuler.net/problem=1

total_sum = 0
for i in range(1000):
    if (i%3 == 0 or i%5 == 0):
        total_sum = total_sum+i
print total_sum

I want to receive an advice for my code... Thank you in advance! :D [1]: https://i.sstatic.net/zE82e.png

MTHL
  • 535
  • 1
  • 5
  • 6