Database System Concepts
Database System Concepts
7th Edition
ISBN: 9780078022159
Author: Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher: McGraw-Hill Education
expand_more
expand_more
format_list_bulleted
Bartleby Related Questions Icon
Related questions
Topic Video
Question
thumb_up100%
use Python
Please follow the instructions :)
Transcribed Image Text:# Lab 9 – Dictionaries
## 1. Course Information
Write a program that creates a dictionary containing course numbers and the room numbers where the courses meet. The dictionary should have the following key-value pairs:
**Course Number (key) | Room Number (value)**
- CS101 | 3004
- CS102 | 4501
- CS103 | 6755
- NT110 | 1244
- CM241 | 1411
The program should also create a dictionary containing course numbers and the names of the instructors that teach each course. The dictionary should have the following key-value pairs:
**Course Number (key) | Instructor (value)**
- CS101 | Haynes
- CS102 | Alvarado
- CS103 | Rich
- NT110 | Burke
- CM241 | Lee
The program should also create a dictionary containing course numbers and the meeting times of each course. The dictionary should have the following key-value pairs:
**Course Number (key) | Meeting Time (value)**
- CS101 | 8:00 a.m.
- CS102 | 9:00 a.m.
- CS103 | 10:00 a.m.
- NT110 | 11:00 a.m.
- CM241 | 1:00 p.m.
The program should let the user enter a course number, then it should display the course’s room number, instructor, and meeting time.
If the course is not in the dictionary, a message should be displayed. The program should contain a loop which continues to ask for a course number until the user chooses to quit.
### Sample Dialog:
```
Enter a course number or press enter to stop: absdfs
absdfs is an invalid course number.
Enter a course number or press enter to stop: CS101
The details for course CS101 are:
Room: 3004
Instructor: Haynes
Time: 8:00 am
Enter a course number or press enter to stop:
>>>
```
Your programs should conform to the Programming Style Requirements as listed in Blackboard under Lab Assignments. You should have 1 .py file to turn in.
Expert Solution
Check MarkThis question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
bartleby
This is a popular solution
bartleby
Trending nowThis is a popular solution!
bartleby
Step by stepSolved in 4 steps with 2 images
Knowledge Booster
Background pattern image
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- USE PYTHON PLEASE (give the same output as the instruction given) Program Specifications Write a program to calculate a course grade given points for homework, quizzes, practice question, and Survey. Grades are calculated differently for undergrads, grads and distance learners.Note: this program is designed for incremental development. Complete each step and submit for grading before starting the next step. Only a portion of tests pass after each step but confirm progress.Step 1 Read from input student status (str). If input is not one of "UG" (undergrad), "G" (grad), or "DL" (distance learner), print an error message and exit the program. Otherwise read from input floats for homework points, quiz points, Practice score, and Survey score. Calculate each category's average using maximum points for homework (800), quizzes (400), Practice question (150), and Survey (200). Output category averages as a percentage using print(f"Homework: {homework:2.1f}%"). Submit for grading to confirm two...arrow_forwardCan you please help me answer part C of this question in python. Include screenshots of your code for better understanding. :) (see image)arrow_forward(python) When creating variables, the names can consist of which of the following: Upper case letters Lower case letters Underscores (_) Digits All of the abovearrow_forward
- 2- Given an integer x = 5, convert it into a float. (Python)arrow_forwardChoose corect option: Ludo is an good example of a) Dfa b) NDFA c) All d) fsmarrow_forward11 - Python program in which Smith deposits 45,000ドル at a bank at an interest rate of 12.5% per year. How much interest will he earn at the end of 5 years? (Search the formula for simple interest).(Python code)arrow_forward
- Help please with how to code this in pythonarrow_forwardGeneral Requirements Create a folder named with your surname followed by 2 (example smith2). In this folder, write Python programs to solve the problems described below. Use the suggested names for your programs. Start each program with your name and SPC ID# in a comment. See page 39 for how to write comments. Plan the steps for each program by writing pseudocode at the beginning of your program. See page 34. Write your pseudocode as comments immediately after your name and SPC ID#. Good pseudocode is required for full points. Add more comments in each program to explain what your code is doing. Do not go your own way by writing a program that ignores the requirements. Solve the problem as the requirements specify. Where formatted numbers are required in output, use f-strings as on pages 70-78. When done, you have to zip/compress your folder for submitting. Do this by right-clicking on your folder and selecting "Send to" > "Compressed (zipped) folder". This will make a zip...arrow_forwardSir/ma'am how to check memory leakage of this programarrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Text book imageDatabase System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationText book imageStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONText book imageDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- Text book imageC How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONText book imageDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningText book imageProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education
Text book image
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Text book image
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Text book image
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
Text book image
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Text book image
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Text book image
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education