Skip to content

Instantly share code, notes, and snippets.

@henkjanverkerk
Last active April 6, 2016 08:24
Show Gist options
  • Save henkjanverkerk/7bf0d70dbc33dddc7a24e44264b42566 to your computer and use it in GitHub Desktop.
Save henkjanverkerk/7bf0d70dbc33dddc7a24e44264b42566 to your computer and use it in GitHub Desktop.
Simple password generator
import random
def main():
length = int(raw_input('How long should your password be?\n'))
print('Here's the password I generated: ' + ''.join(random.sample('QWERTYUIOPASDFGHJKLZXCVBNM1234567890abcdefghijklmnopqrstuvwxyz1234567890!@$()_', length)))
main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment