Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Write a program that contains 2 functions, main ( ) and again ( ) , and 3 dictionaries. In the main ( ) function place
Write a program that contains functions, main and again and dictionaries.
In the main function place the dictionaries.
Create a dictionary named location containing course numbers and the room numbers of the rooms where the courses meet. The dictionary should have the following keyvalue pairs:
Course Number key Room Number value
COSC
FIN
BIOL
HUM
Phys
The program should also create a dictionary named profs containing course numbers and the names of the instructors that teach each course. The dictionary should have the following keyvalue pairs:
Course Number key Instructor value
COSC Farrell
FIN Alvarado
BIOL Rich
HUM Burke
PHYS Lee
The program should also create a dictionary named when containing course numbers and the meeting times of each course. The dictionary should have the following keyvalue pairs:
Course Number key Meeting Time value
COSC : pm
FIN : am
BIOL : am
HUM : am
PHYS : pm
The again function should be used to ask if the user wants to look up another course. If the answer is no ends the program. This is like how you used the again function used in a previous assignment
Remember that the response can be either upper or lower case. If unsure how to handle this check out Table and the explanation
The program should let the user enter a course number, then it should display
if the course not listed, print the following replacing the with actual data
The is an invalid course number.
if listed, print the courses room number, instructor, and meeting time Notice I want a formatted table
The details for course are:
Room:
Instructor:
Time:
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started