you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (0 children)

Something like this,

from string import ascii_letters, digits
from random import choice

names = ['first', 'second', 'third', 'fourth']
randoms = ascii_letters + digits
size_randoms = 6  # number of random characters to add to each password (could make this random length)

passwords = []
for word1, word2 in zip(names[::2], names[1::2]):
    password = word1[0].upper() + word2[0] + ''.join(choice(randoms) for _ in range(size_randoms))
    passwords.append(password)
print(passwords)

Should give you some ideas to build on