Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import random
- mylist = ['a','b','c','d','e','f','g','h',1,2,3,4,5,6,7,8,9]
- def password_gen(length, list):
- mychoices = random.choices(list, k =length)
- pw = " "
- for index in range(len(mychoices)):
- pw =pw+str(mychoices[index])
- return pw
- print(password_gen(16, mylist))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement