Question: Objective: To work with lists, strings in Python Assignment: Create a menu-driven python program that performs the following tasks based on the option number. 1.

Objective:

To work with lists, strings in Python Assignment:

Create a menu-driven python program that performs the following tasks based on the option number.

1. Employee Details

2. Organization Details

3. Display

4. Exit

Two empty lists should be created, one for maintaining the Employee names and the other for maintaining the names of the organizations in which each employee works. The program should accept an option number (which is an integer) from the user. Based on the input option number, the following tasks are to be performed.

If the user input option 1, accept the name of the Employee and store each name in the first list. Display the contents of the first list.

If the user inputs option 2, accept the name of the Organization in which the employee works and store the organization details in the second list. Display the contents of the second list.

If the user inputs option 3, display the employee names and respective organization names in a tabular format by using string formatting as shown below.

Employee_Name Organization

Jack Accenture

Sam Microsoft

Eddie Google

Note: Use loops for implementing the menu and only option to exit from the menu should be when the user inputs option 4. Also, use string formatting for displaying in table format.

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!