Skip to content

Commit 3940fe3

Browse files
Create day_1_username_and_password-generator.py
1 parent e11af60 commit 3940fe3

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
print("Welcome to the 'Simple Username and Password Generator'")
2+
print(' ')
3+
4+
fname = input("What's is your first name?\n")
5+
6+
print(' ')
7+
lname = input("What's is your last name?\n")
8+
9+
print(' ')
10+
dob = input("When is your birthday? Type in mm/dd/yyyy format.\n")
11+
dob1 = dob[1]
12+
dob2 = dob[6:-1]
13+
14+
print(' ')
15+
soc = input("What is the last 4 digits of your social security number?\n")
16+
17+
import random
18+
import string
19+
characters = string.ascii_letters + string.digits + string.punctuation
20+
random = ''.join(random.choice(characters) for i in range(4))
21+
22+
23+
print(' ')
24+
print("Your Username is: " + fname[0] + "" + lname[0:5] + soc)
25+
print("Your unique password is: " + dob1 + fname[1::2] + "" + dob2 + random)

0 commit comments

Comments
 (0)