Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Using Object-Oriented Programming Abstract Data Types (ADT) principles in Python: 1.1 Create a class Patient File Reader () for retrieving the patient data from the
Using Object-Oriented Programming Abstract Data Types (ADT) principles in Python: 1.1 Create a class “Patient File Reader ()” for retrieving the patient data from the given text file (this should have been created by the student).
Steve Biko Hospital is in the process of storing her patient's data in a format stipulated in Table 1.1 below which will, in turn, be uploaded to a database. Note that the patient numbers are arranged in ascending order. The hospital office administrator uses a specific format to capture the patient's data in a text file in no particular order. Suppose the specific format structure is defined line by line where each patient's data consists of the following: patient number, surname, name, age group, sex, and weight, which are captured in this order. The age groups are given with descriptions as follows: Neonate (first 4 weeks of life), Infant (1 month to 1 year), Toddler (1- 3 years), Pre-school child (3-5 years), School Age Child (6- 12 years), Adolescent (13- 18 years), Young Adult (19 - 40), Middle Age Adult (41 - 65 years), and Older Adult (over 65 years) which are often represented by digits 1 to 9 (where 1 is Neonate and 9 is Older Adult). You are expected to develop a Python program that will produce the output as shown Table 1.1 by creating a text file using the format described above, which will serve as the input to your program. PATIENT DATA PATIENT NO. SURNAME NAME AGE GROUP SEX WEIGHT (KG) Young Adult School Age Child Infant Older Adult 10005 Linda Khumalo 56.40 Mokoena Mkhize Nkosi 10012 M 9.82 10015 Dlamini M 5.60 10100 Sithole Mahlangu M 91.77 10132 Ntombi Zulu Pre-school child F 10.61 Number of patients: 5 Table 1.1: Patient Data
Step by Step Solution
★★★★★
3.40 Rating (156 Votes )
There are 3 Steps involved in it
Step: 1
Please refer to the screenshot of the code to understand the indentation of the code Language C Visual Studio Console Project NET version 472 Project ...Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started