Question: The Patient class (patient.py) will have an additional attribute, procedure_list. This list will contain all the procedures performed on the patient. In addition, Patient will



The Patient class (patient.py) will have an additional attribute, procedure_list.  This list will contain all the procedures performed on the patient.  In addition, Patient will have a calculate_charges function that returns the total of all procedures on the procedure list.  

Create one child from Patient:  InPatient (inpatient.py).  InPatient has an additional attribute of days representing how many days the patient stayed in the hospital. 

The test case will do the following:

Write test case (patienttest.py ) to create Patient Jones as below and perform the object creations described in the book.  Then, add procedures Physical Exam and X-ray to Mr. Jones.  Sample output will be

First Name: James

Middle Name: Edward

Last Name: Jones

Address: 123 Main Street

City: Billings

State: Montana

ZIP: 59000

Phone: 406-555-1212

Emergency Contact: Jenny Jones

Emergency Phone: 406-555-1213

Procedure: Physical Exam

Date: 8-24-2019

Practitioner: Dr. Irvine

Charge: 250.00

Procedure: X-ray

Date: 8-24-2019

Practitioner: Dr. Jamison

Charge: 500.00

Procedure: Blood Test

Date: 8-24-2019

Practitioner: Dr. Smith

Charge: 200.00

Procedures performed on the patient are

Procedure: Physical Exam

Date: 8-24-2019

Practitioner: Dr. Irvine

Charge: 250.00

Procedure: X-ray

Date: 8-24-2019

Practitioner: Dr. Jamison

Charge: 500.00

The total charge for Jones is $750.00

The test case will also create patient Will Thomas Smith, 456 South Street, Dallas, Texas, 75050, 214-555-1234, Carol Smith, 214-4444567, with days of 3.  Print the inpatient information to the prompt and then print the total charge at $50 a day.  Remember to access the patient data; not hard code any information in the main.

The printout should be:

First Name: Will

Middle Name: Thomas

Last Name: Smith

Address: 456 South Street

City: Dallas

State: Texas

ZIP: 75050

Phone: 214-555-1234

Emergency Contact: Carol Smith

Emergency Phone: 214-555-4567

Days 3

The total charge for Smith is $150.00

Step by Step Solution

3.44 Rating (154 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Lets break down the task and develop the solution step by step Step 1 Define the Patient Class The Patient class should have several attributes name details address and contact information Additionall... View full answer

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 Programming Questions!