Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. Extend the BMI program from the previous lesson. Rather than terminating the program on invalid input, display an error message and ask the

  

1. Extend the BMI program from the previous lesson. Rather than terminating the program on invalid input, display an error message and ask the user to enter valid input. Provide a way for the user to terminate the program instead if they choose. 2. Extend the BMI program above. Add a loop to the main program that continues asking for input after displaying each BMI result. Provide a way for the user to terminate the program instead if they choose. 3. Update program and function documentation, consistent with the documentation standards for your selected programming language. 4. Extend the BMI program to displays a BMI table, with columns for height from 58 inches to 76 inches in 2-inch increments and rows for weight from 100 pounds to 250 pounds in 10-pound increments. Reuse the conversion/calculation functions from the BMI program above. Include appropriate program and function documentation, consistent with the documentation standards for your selected programming language. this is what i did # This program calculates a person's Body Mass Index (BMI) based on their weight in pounds and height in feet and inches. # The program then classifies the person's BMI as underweight, normal, or overweight based on the recommendations from the National Institutes of Health (NIH). # Constants for the BMI classification ranges UNDERWEIGHT_BMI = 18.5 NORMAL BMI = 24.9 OVERWEIGHT_BMI = 29.9 print("Please Enter your name") name = input() #Ask the user for their weight in pounds weight_pounds = float(input ("Enter your weight in pounds: "))

Step by Step Solution

3.43 Rating (153 Votes )

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

Step: 3

blur-text-image

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

Systems analysis and design

Authors: kenneth e. kendall, julie e. kendall

8th Edition

135094909, 013608916X, 9780135094907, 978-0136089162

More Books

Students also viewed these Programming questions