Last active
April 22, 2019 12:59
-
-
Save DOKL57/e54ac54675d6c597dd351d554f60148b to your computer and use it in GitHub Desktop.
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
import random | |
num = input('login ') | |
pas = '' | |
for x in range(16): #Number of characters in password (16) | |
pas = pas + random.choice(list('1234567890abcdefghigklmnopqrstuvyxwzABCDEFGHIGKLMNOPQRSTUVYXWZ')) #The characters from which the password will be composed | |
print('Hello, ', num, 'your password is: ', pas) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
import random
login = ["login","admin","user"]
for x in login:
passwd = list('1234567890abcdefghigklmnopqrstuvyxwzABCDEFGHIGKLMNOPQRSTUVYXWZ!@#$%^&*()-=_|/?><')
random.shuffle(passwd)
passwd = ''.join([random.choice(passwd) for x in range(10)])
input()