Last active
May 18, 2021 07:13
-
-
Save bergantine/9732714 to your computer and use it in GitHub Desktop.
Safari-style #python #password Generator
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from random import choice | |
def genCode(len): | |
return ''.join([choice('abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789') for i in range(len)]) | |
print '%s-%s-%s-%s' % (genCode(3), genCode(3), genCode(3), genCode(3)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment