Skip to content

Instantly share code, notes, and snippets.

@soravux
Last active December 15, 2015 23:08
Show Gist options
  • Save soravux/5337619 to your computer and use it in GitHub Desktop.
Save soravux/5337619 to your computer and use it in GitHub Desktop.
Solution to the Project Euler problem #1 - For the multigrad blog (entry 1)
import timeit
timeit.timeit(
"sum(x for x in range(1000) if x % 5 == 0 or x % 3 == 0)",
number=10000
) / 10000.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment