Question: Modify the username.py program (see the lecture slide) to generate usernames using the users first initial, followed by up to 3 first letters of the

Modify the username.py program (see the lecture slide) to generate usernames using the users first initial, followed by up to 3 first letters of the users last name, and a number of total characters in the last name. User input can be up- or low-case. But the generated usernames contains only low-case characters and a number.

For example, if the persons name is Albert Einstein the username shall be aein8

Tip: use len() function and strings lower() method

To create the program(10 points): :

1. Create a module named h02_username2.py from the directory hw

2. Record your name, class number, and date of creation using python comment statement.

3. Write the code to implement the required tasks.

When you have completed the program, run the program and capture and paste the output below:

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!