Question: Dictionary doctors _ room contains key - value pairs that represent the room number of each doctor. Dictionary patient _ directory contains key - value
Dictionary doctorsroom contains keyvalue pairs that represent the room number of each doctor. Dictionary patientdirectory contains keyvalue pairs that represent the patient in each room. String doctorname is read from input. Complete the following tasks:
Assign roomnum with the value associated with key doctorname in doctorsroom. Any string that is not a key in doctorsroom has default value
Use pop to remove roomnum from patientdirectory and assign patientname with the value returned. Any number that is not a key in patientdirectory has default value no one'.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
