ProjectEuler/problem1.py

6 lines
155 B
Python
Raw Normal View History

2019-12-29 02:48:59 +01:00
"""Multiples of 3 and 5."""
mult3 = set(i for i in range(1000) if i % 3 == 0)
mult5 = set(i for i in range(1000) if i % 5 == 0)
print(sum(mult3 | mult5))