Answered step by step
Verified Expert Solution
Question
1 Approved Answer
please help ASAP I just need the dummy return statements fixed. this is a working code. please read the // lines ... please help! please
please help ASAP I just need the dummy return statements fixed. this is a working code. please read the // lines ... please help!
please help asap
1: Unit test 0/2 Testing avgDaysin Hospital 15.8571 O Test feedback 15.8571 avgDays InHospital() incorrectly returned 0 0/2 2. Unit test Testing percentageHospitalized() 0.714286 Test feedback 0.714286 percentageHospitalized incorrectly returned 0 02 3: Unit test A Testing percentageAge Hospitalized() 0.75 Test feedback 0.75 percentageAgeHospitalized () incorrectly returned 0 0/2 4 Unit testa Testing index MostDays) Test feedback indexMost Days ( incorrectly returned 0 66 0 Karen Mary McIntyre Leonardo Sam Gibson Kaylan Camille Keller Carson Nolan Han Bernard Jack Hart 13529318 87929139 45893209 88792390 98234925 01 65 0 9. Cough, Diff. Breathing, Eatigue, Stuffy or Runn Fever, Cough, Diff. Breathing, Fatigue, Muscle Headache, New Loss Taste or Smell, Sore Throat, Fatigue, Muscle or Body Aches, Sore Throat, Stu: Fever, Diff. Breathing, Fatigue, Muscle or Body 69 98 20 James Ray Wood - 70934578, age 85, required the longest hospitalization of 29 days. Average days in hospital for all patients: 0.00 The percentage of patients requiring hospitalization: 0.00% Age Percentage Range Hospitalized 0 - 4 5- 17 18 - 49 50 - 64 65 - 74 75 - 84 >= 85 0.00% 0.00% 0.008 0.00% 0.00% Number of Symptoms Patient Name Age 85 0 19 0 0 0 James Ray Wood Sophia Helen Clarke J'Layne Blair Harris Wade Brent Hughes Zoe Ann Wright Landon Matthew Lee Janice Joy Rodriquez Jennifer Kay Jones Sharon Renee Nguyen Werner Allen Garcia 85 55 22 35 0 0 90 0 0 64 0 69 85 0 119 120 121 / 122 The percentageHospitalized() function accepts as arguments the array that holds the number of days in the 123 hospital and the number of patients. The function uses a loop to traverse through the days array and if 124 a patient spent time in the hospital (if number of days is > ), then a counter is incremented. When 125 the loop terminates, the counter holds the number of people who were hospitalized. The percentage is 126 computed by dividing the counter by the number of patients. The function returns this percentage in 127 decimal format (i.e. - the value is not multiplied by 100). 128 */ 129 double percentageHospitalized(int days[], int numPatients) 130 131 return 8; // dummy return statement 132 ) 133 134 135 The percentageAge Hospitalized function accepts as arguments the days array, age array, number of patients, 136 and a lower and upper age range. This function uses a loop to traverse through the days array and keeps 137 count of the number of people in the given age range (i.e. age >= lower and age = 85" > patientID[i] >> age[i] >> days InHospital[i]; 38 for (int j = 0; j > patientsymptoms[i][j]); can ignore(); 24 25 11 Output the header of the table followed by a row of dashes cout 2 #include
Step by Step Solution
There are 3 Steps involved in it
Step: 1
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