Question: Dictionary doctors _ room contains key - value pairs that represent the room number of each doctor. Dictionary patient _ directory contains key - value

Dictionary doctors_room contains key-value pairs that represent the room number of each doctor. Dictionary patient_directory contains key-value pairs that represent the patient in each room. String doctor_name is read from input. Complete the following tasks:
Assign room_num with the value associated with key doctor_name in doctors_room. Any string that is not a key in doctors_room has default value -999.
Use pop() to remove room_num from patient_directory and assign patient_name with the value returned. Any number that is not a key in patient_directory has default value 'no one'.

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!