Skip to content

Instantly share code, notes, and snippets.

@bfagundez
Created July 9, 2015 18:51
Show Gist options
  • Save bfagundez/71d94c1f690c9fbdfa96 to your computer and use it in GitHub Desktop.
Save bfagundez/71d94c1f690c9fbdfa96 to your computer and use it in GitHub Desktop.
combinations
a = ('a'..'z').to_a
b = ['1','2','3','4','5','6','7','8','9','0']
c = a+b
File.open('randomness.txt','w'){|f|
c.combination(7).map(&:join).each{|combo|
f.write(combo+'\n')
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment