Answered step by step
Verified Expert Solution
Link Copied!
Question
1 Approved Answer

4. Write a program that calculates the multiple body mass index (BMI) where the program read multiple weight and height and stored it into a

image text in transcribed

4. Write a program that calculates the multiple body mass index (BMI) where the program read multiple weight and height and stored it into a parallel array weight[] and height[], then the program calculates and display BMI based on weight in kilograms (kg) and height in meters (m) based on the following formula: BMI = weight heightx height For each BMI values, display the weight status of underweight, normal, overweight, or obese, based on the following table: BMT = 46.0 Weight Status Underweight Normal Overweight Obese At the end of the program, determine the percentage of each weight status that have been calculated. The sample output should be as follows: Enter height (m) and weight (kg) : 1.72 100 Enter more? 'Y' for yes, 'N' for no : Y Enter height (m) and weight (kg) Enter more? 'Y' for yes, 'N' for no : 1.56 79 : 1.63 67 Enter height (m) and weight (kg) Enter more? 'Y' for yes, 'N' for no Enter height (m) and weight (kg) Enter more? 'Y' for yes, 'N' for no : 1.51 45 : 1.65 132 Enter height (m) and weight (kg) Enter more? 'Y' for yes, 'N' for no Enter height (m) and weight (kg) Enter more? 'Y' for yes, 'N' for no : 1.69 63 : N Height=1.72, Weight=100.00, BMI=33.80 Height=1.56, Weight= 79.00, BMI=32.46 Height=1.63, Weight= 67.00, BMI=25.22 Height=1.51, Weight= 45.00, BMI=19.74 Height=1.65, Weight=132.00, BMI=48.48 Height=1.69, Weight= 63.00, BMI=22.06 Percentage Underweight = 50.00 Percentage Normal = 33.33 Percentage overweight = 0.00 Percentage Obese = 16.67

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image
Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

MySQL/PHP Database Applications

Authors: Jay Greenspan, Brad Bulger

1st Edition

978-0764535376

More Books

Students explore these related Databases questions

Question

(1) (1)

Answered: 3 weeks ago