Skip to content

Instantly share code, notes, and snippets.

Created February 5, 2013 11:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save anonymous/4713925 to your computer and use it in GitHub Desktop.
Save anonymous/4713925 to your computer and use it in GitHub Desktop.
numbers = [*1...100]
sieves = numbers.reject do |n|
2.upto(100) do |key|
n != key && n.to_f % key == 0
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment