1. Extend the BMI program from the previous lesson. Rather than terminating the program on invalid...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
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: ")) 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: "))
Expert Answer:
Related Book For
Systems analysis and design
ISBN: 978-0136089162
8th Edition
Authors: kenneth e. kendall, julie e. kendall
Posted Date:
Students also viewed these programming questions
-
Whirly Corporation's contribution format income statement for the most recent month is shown below: Total Sales (7,600 units) Variable expenses $ 235,600 144,400 Contribution margin 91,200 Per Unit $...
-
This assignment reviews object-oriented programming concepts such as classes, methods, constructors, accessor methods, and access modifiers. It makes use of an array of objects as a class data...
-
In this project, we will write a program that controls a quiz show, much like the many popular TV shows. The program will read in a group of questions and their multiple choice answers, storing them...
-
Which statement is correct? A) Tax credits reduce tax liability on a dollar-for-dollarbasis. B) Tax deductions reduce tax liability on a dollar-for-dollarbasis. C) The benefit of a tax credit depends...
-
A 1-kW, 120-V, 60-Hz capacitor-start motor has the following parameters for the main and auxiliary windings (at starting): Zmain = 4.82 + j7.25 main winding, Zaux = 7.95 + j9.21 auxiliary winding a....
-
Identify processes that are suitable for making small production runs of plastic parts, such as quantities of 100 or fewer. Explain?
-
Sarah serves as Chief Executive Officer (CEO) for Biostate Corporation. Biostate is a pharmaceutical company that conducts research on the development of new cancer drugs. It has developed several...
-
A paper mill is considering two types of pollution control equipment. The firm wants a 12% rate of return on any avoidable increments of investment. Which equipment should be purchased?...
-
1. Define ADT (Abstract Data Type)? 2. Mention the features of ADT.? 3. Define List ADT? 4. What are the ways of implementing linked list? 5. What are the types of linked lists?
-
Enter the following sales transaction into the Ledger/Journal. You have negotiated the sale of Mr and Mr Emerald's home at 8 Knowle Court, Ocean Grove for $1,000 000. The purchasers, Mr and Mrs Teal...
-
Suppose stock returns can be explained by a two-factor model. The firm-specific risks for all stocks are independent. The following table shows the information for two diversified portfolios: 1 2...
-
Many workers who move to New York City for a new job get a raise in their pay, but this raise in pay does not completely cover the increased cost of living. What does this say about the desirability...
-
People engaged in the hospitality sector usually receive lower wages, and tips make up a certain percentage of their income. However, some occupations in a hotel may provide considerably lower daily...
-
Many taxes in the United States are collected according to the ability-to-pay principle. Can you think of a government service that is taxed according to the benefits received principle?
-
The issue of asymmetric information in news reporting has acquired greater importance in the age of the Internet. In 2013, the Oxford Internet Survey reported that traditional media like TV and the...
-
The government taxes both clothing and tobacco. For a similarly sized tax, would you expect the quantity demanded of clothing or tobacco to be more affected?
-
Match the following examples Element Compound Homogeneous mixture Heterogeneous mixture [Choose] [Choose] [Choose] [Choose]
-
Coastal Refining Company operates a refinery with a distillation capacity of 12,000 barrels per day. As a new member of Coastal's management team, you have been given the task of developing a...
-
As a fourth team member listening to the foregoing exchange, formulate three suggestions that would help Hy, improve his approach to goal formation and presentation. How well motivated do you think...
-
Brainstorm with your team members about what types of output are most appropriate for a variety of executives and high-level managers of Dizzyland, a large theme park in Florida. Include a list of...
-
The following ports of call are available for the Pacific Holiday Company: Create the PORT OF CALL element. Examine the data to determine the length and format of theelement. Apia Pago Pago Bora Bora...
-
Explain the difference between the credit risk and the market risk in a swap.
-
Explain two ways a fixed-for-fixed currency swap can be valued.
-
A national news organization developed the graphic shown in Figure 22 to illustrate the change in the highest marginal tax rate effective January 1, 2013. Why might this graph be considered...
Study smarter with the SolutionInn App