Question: It is a Python Program question. Please use minimum built-in function, Python Program. class Person: def __init__(self, name, contact): self.name = name self.contact = contact

It is a Python Program question. Please use minimum built-in function, PythonProgram. class Person: def __init__(self, name, contact): self.name = name self.contact =contact def __str__(self): s = f"Name: {self.name} Contact: {self.contact}" return s #Writeyour code here d = Doctor("Dr Strange", "4585632", "Neurosurgery", "DMC") d.add_patients("Dhaka AbdurRahim", "Dhaka John Cena", "Narayanganj John Wick", "Comilla CM Punk") print("1.=========================================================") print(d)It is a Python Program question. Please use minimum built-in function,

print("2.=========================================================") d.show_patient_list("Dhaka") print("3.=========================================================") d.show_patient_list("Rajshahi") print("4.=========================================================") d.add_patients("Narayanganj Naruto Uzumaki") print("5.=========================================================") print(d) print("6.=========================================================") eng= Engineer("Howard Wolowitz", "982685", "Mechanical") eng.add_projects("Mongol Tori Bangladesh", "Duburi Bangladesh", "Curiosity RoverUSA", "Perseverence USA") print("7.=========================================================") print(eng) a Bookmark this page Hello! Hope you

Python Program.

class Person: def __init__(self, name, contact): self.name = name self.contact = contact def __str__(self): s = f"Name: {self.name} Contact: {self.contact}" return s #Write your code here d = Doctor("Dr Strange", "4585632", "Neurosurgery", "DMC") d.add_patients("Dhaka Abdur Rahim", "Dhaka John Cena", "Narayanganj John Wick", "Comilla CM Punk") print("1.=========================================================") print(d) print("2.=========================================================") d.show_patient_list("Dhaka") print("3.=========================================================") d.show_patient_list("Rajshahi") print("4.=========================================================") d.add_patients("Narayanganj Naruto Uzumaki") print("5.=========================================================") print(d) print("6.=========================================================") eng = Engineer("Howard Wolowitz", "982685", "Mechanical") eng.add_projects("Mongol Tori Bangladesh", "Duburi Bangladesh", "Curiosity Rover USA", "Perseverence USA") print("7.=========================================================") print(eng)

a Bookmark this page Hello! Hope you are well. I need help with the following question. Thank you. Implement the design of the Doctor and Engineer class derived from Person class so that the following code generates the output below: class Person: def __init__(self, name, contact): self.name = name self.contact = contact defstr_(self): S = f'Name: {self.name} Contact: {self.contact)" returns #Write your code here d = Doctor("Dr Strange", "4585632", "Neurosurgery", "DMC") d.add_patients("Dhaka Abdur Rahim", "Dhaka John Cena", "Narayanganj John Wick", "Comilla CM Punk") print("1. ==== print(d) print("2.== ====') d.show_patient_list("Dhaka") print("3.==== d.show_patient_list("Rajshahi") print("4.==== ===') d.add_patients("Narayanganj Naruto Uzumaki") print("5. print(d) print("6.==== eng = Engineer("Howard Wolowitz", "982685", "Mechanical") eng.add_projects("Mongol Tori Bangladesh", "Duburi Bangladesh", "Curiosity Rover USA", "Perseverence USA") print("7 print(eng) EEEEEEEE ====== ============= OUTPUT 1. ======== Doctor Details: Name: Dr Strange Contact: 4585632 Speciality: Neurosurgery Hospital: DMC Patients List: {Dhaka": ['Dhaka Abdur Rahim'. 'Dhaka John Cena'). "Narayanganj': ['Narayanganj John Wick]. 'Comilla': [Comilla CM Punk']} 2. ========== Patients from Dhaka: Dhaka Abdur Rahim Dhaka John Cena 3. ====================== Dr Strange has not patients from Rajshahi 4. =============== 5. ========== Doctor Details: Name: Dr Strange Contact: 4585632 Speciality: Neurosurgery Hospital: DMC Patients List: {Dhaka": ['Dhaka Abdur Rahim'. 'Dhaka John Cena']. 'Narayanganj": ['Narayanganj John Wick', 'Narayanganj Naruto Uzumaki'), 'Comilla': ['Comilla CM Punk']} 6.=========== 7. ====EEEEE Engineer Details: Name: Howard Wolowitz Contact: 982685 Field: Mechanical Project List: {Bangladesh": ['Mongol Tori Bangladesh', 'Duburi Bangladesh'], "USA': ['Curiosity Rover USA', 'Perseverence USA']} === ======== ===EEEEE

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!