Skip to content

Instantly share code, notes, and snippets.

@matthiasplappert
Created November 18, 2011 14:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save matthiasplappert/1376531 to your computer and use it in GitHub Desktop.
Save matthiasplappert/1376531 to your computer and use it in GitHub Desktop.
menge = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
menge.each do |x|
if x != 0 then
menge.each do |y|
if y != 0 then
if ((x * y) % menge.length == 0) then
print x.to_s + " * " + y.to_s + " % " + menge.length.to_s + " = 0\n"
end
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment