Question: Instructions: For this assignment, refer to instructions below list the assignment requirements, Patient File and BMI A text file contains patient ID, height (in inches),

Instructions: For this assignment, refer to
Instructions: For this assignment, refer to instructions below list the assignment requirements, Patient File and BMI A text file contains patient ID, height (in inches), and weight (in pounds). For exampl patient-id height,weight : ' P0123,66,150 P4354,68,164 . a) Write a program that reads each line of the fi displays each patient's ID and their BMI to the BMI = weight / height2 x 703 le, calculates the BMI for each patient, and screen. The equation for BMI is: b) Enhance your program so that the patient ID and BMI are saved to a file called bmi.txt. ) Enhance your program so that if the height or weight data in the file are not numeric, the program will display an error message to the screen including the patient's ID. 1.Create a Python code file named MS5Lab_FileProcessing_FirstLast.py (replace "FirstLast" with your own name) 2. Add a title comment block to the top of the new Python file using the following form # A brief description of the project # Date # CSC121 M5Lab # Your Name 3. Complete Exercise 9 on page 115(Patient File and BMI (@)). (vou will have to create a .txt containing example provided under exercise 9) ' 4. Enhance code completed in step 3 above by completing (b) under same exercise. 5. Enhance code completed in step 4 above by completing (c) under same exercise. 6. In addition to getting the program to complete requirements listed in exercise 9, enhance the program so that patient ID, Height, Weight and BMI are saved to a CSV file called patient _bmi.csv 7. Make sure you submit a zipped folder containing the following;text file you r_ee_ld the information from, the code (couldbe one or two files if you considered modularizing, output file generated by code in step 4, csv file generated by code in step 6

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