Python/Project Euler/Problem 01/sol5.py

9 lines
112 B
Python
Raw Normal View History

a=3
result=0
while a=<1000:
if(a%3==0 and a%5==0):
result+=a
elif(a%15==0):
result-=a
print(result)