-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathUnhackable Password Generator.py
More file actions
39 lines (30 loc) · 1.29 KB
/
Unhackable Password Generator.py
File metadata and controls
39 lines (30 loc) · 1.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import random
letters = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', '1', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', '0', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z']
numbers = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']
symbols = ['!', '#', '$', '%', '&', '(', ')', '*', '+']
print('''
| ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄ ̄|
Welcome to pypassword
|______________|
\ (•◡•) /
\ /
''')
print("Get Your Unhackable Password!!")
letter = int(input("Enter how many letters do you want in your password, Enter numbers like '1' or '5' etc. : "))
number = int(input("Enter how many numbers you want in your password: "))
symbol = int(input("Enter the number of symbols in your Password : "))
password = []
for char in range(1,letter +1):
password.append(random.choice(letters))
for char in range(1,number +1):
password += random.choice(numbers)
for char in range(1, symbol + 1):
password += random.choice(symbols)
# print(password)
# print(type(password))
random.shuffle(password)
# print(str(password))
realpassword = ""
for char in password:
realpassword += char
print(f"Your password is : {realpassword}")