Question: Using If/else: Write a program that calculates a person's body mass index (BMI). The BMI is used to determine whether a person is of optimal
Using If/else: Write a program that calculates a person's body mass index (BMI). The BMI is used to determine whether a person is of optimal weight. A person with a BMI under 18.5 is underweight, between 18.5 and 25 is at optimal weight, between 25 and 30 is overweight and over 30 is obese. Calculate BMI using the formula: BMI = weightInPounds * 703/heightInInches2
Input weight and height with JOptionPanes and display the BMI and the status of a person's condition in a third JOptionPane.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
