Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Input section: Add logic to the input section that will add 3 additional questions about password construction. How long do you want your password? Length

Input section:
Add logic to the input section that will add 3 additional
questions about password construction.
How long do you want your password? Length must be between
10 and 16 in length.
Do you want special characters in your password?
Do you want numbers in your password?
You will validate the password length the user entered and
make sure it is at least 10 but not greater than 16 and that
it can be converted to an integer.
You will add the new input to the employee data list for
later processing.
Classes needed: (in separate py files)
Person class:
Properties: first name, last name, birth_year
Methods: greet person that returns a message and age that
will return a persons age in years based on the current year
Employee class:
Will inherit from the Person class
Properties: password length, use special characters flag, use
numbers flag
Methods: build password that will take the properties and
create a password that will be of the requested length and
have special characters and numbers if the employee request
them.
Process section:
Gather the data entered in a list with the elements being of
type tuple containing first name, last name, birth_year (this
Add a function under the variable section to generate a
username. (see example below) This function will take the
first name, last name and year of birth as parameters along
with a duplicate found flag. The duplicate found flag will
be used in the functions if else logic to generate the
correct type of username. You will then pass the username
back out to the function call.
After the creation of the username, instantiate a copy of the
employee class and pass all the employee data to it including
first name, last name, birth year, password length, use
special characters flag, and use numbers flag.
Within the person class you will create a message and
calculate the persons age in years and store that
information in a list to be printed out in the output
section. In the employee class (which should inherit from
person), you will generate a password of required length and
use special characters and numbers if the employee has
requested. Pass the password back to your main program.
Create a list with the following data in it and add it to the
Employee data dictionary INSTEAD of the content of the
employee tuple. Use the username as the key and a tuple as
the value with the following data: first name, last name,
year of birth, password in a list
Leave the copy and sort of the username list in from last
week.
Output section:
Output is same as last program.
You must then output the following information in this order:
Username
Todays Date
Loop the list with the message and ages and display a message
that reads Hello, XXXX! You are XX years old. This should be
printed after the standard Username and Todays date but
before all the other output listed below.
Username list with all usernames
Employee data dictionary
Username list that has been sorted
What to turn in: Take a screen shot of your RUNNING program
Upload the screen shot and all 3 py files to blackboard as
Four (4) separate files. You can also zip all 4 files up and turn in that one file.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Power Bi And Azure Integrating Cloud Analytics For Scalable Solutions

Authors: Kiet Huynh

1st Edition

B0CMHKB85L, 979-8868959943

More Books

Students also viewed these Databases questions