Skip to content

Instantly share code, notes, and snippets.

@mwielgoszewski
Created January 20, 2014 15:42
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 mwielgoszewski/8522280 to your computer and use it in GitHub Desktop.
Save mwielgoszewski/8522280 to your computer and use it in GitHub Desktop.
from itertools import chain, cycle, dropwhile, islice, product
import string
def pattern_create(*args):
return ''.join(islice(chain.from_iterable(cycle(product(string.uppercase, string.lowercase, string.digits))), *args))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment