1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
omeli [17]
3 years ago
11

Write a program that calculates and displays a person’s body mass index (BMI). The BMI is often used to determine whether a pers

on with a sedentary lifestyle is overweight or underweight for his or her height. A person’s BMI is calculated with the following formula:
BMI = weight x 703 / height2

where weight is measured in pounds and heightis measured in inches. The program should ask the user to enterhis/her weight and height. The program should display a message indicating whether the person has optimal weight, is underweight, or is overweight. A sedentary person’s weight is considered optimal if his or her BMI is between18.5 and 25. If the BMI is less than 18.5, the person is considered underweight. If the BMI valueis greater than 25, the person is considered overweight
Computers and Technology
1 answer:
GuDViN [60]3 years ago
6 0

Answer:

<em>This program is written using C++</em>

<em>Comments are used to explain difficult lines</em>

<em>Program starts here</em>

#include<iostream>

using namespace std;

int main()

{

//Declare variables

float BMI, Height,Weight;

// Prompt user for inputs

cout<<"Ener Height (in inches): ";

cin>>Height;

cout<<"Enter Weight (in pounds): ";

cin>>Weight;

//Calculate BMI

BMI = (Weight * 703)/(Height * Height);

cout<<"Your Body Mass Index (BMI) is "<<BMI<<endl;

//Test and print whether user is underweight, overweight or optimal

if(BMI>=18.5&&BMI<=25)

{

 cout<<"You have an optimal weight";

}

else if(BMI<18.5)

{

 cout<<"You are underweight";

}

else if(BMI>25)

{

 cout<<"You are overweight";

}  

return 0;

 

}

<em>See attachment for .cpp source file</em>

Download cpp
You might be interested in
PLZ HELP WILL MARK BRANLIEST Jargon is:
77julia77 [94]

Answer:C language that include terms that only a select

Explanation:

It’s the right one

7 0
3 years ago
What statement is accurate in regards to
lorasvet [3.4K]

The statement that is accurate in regards to sharing workbooks is that You must add the feature to the Quick Access Toolbar

<h3>What does a shared workbook implies?</h3>

The term connote the act of sharing an Excel file. Here, a person can give other users any form of access to the same document.

Sharing workbook is one that allow people to make any kinds of edits at the same time, which saves a person the trouble of keeping track of different versions.

Learn more about workbooks from

brainly.com/question/5450162

7 0
2 years ago
Which piece of code results in the following? Italics
andriy [413]
Italics

Italics

Italics

Italics


7 0
3 years ago
Which of the following binary numbers is equivalent to decimal 4?
melomori [17]

Answer:

b so easy

Explanation:

5 0
3 years ago
Read 2 more answers
A system administrator at Universal Containers created a new account record type. However, sales users are unable to select the
Kobotan [32]

Answer:

The record type has not been added to the sales user profile.

The record type has not been activated.

Explanation:

They are two possible reasons in the available options for the sales user not being able to select the record type when creating new account records. they are :

  • The record type has not been added to the sales user profile.
  • The record type has not been activated.
4 0
3 years ago
Other questions:
  • Why is it a mistake to put email addresses of people who don't know each other in the "To:" field?
    8·2 answers
  • What is the difference between ARM and INTEL Chip?
    6·1 answer
  • Fact Pattern: A sales transaction record designed to contain the information presented below. Column Information 1-10 Customer a
    13·1 answer
  • A network administrator for a small company is contemplating how to scale the network over the next three years to accommodate p
    13·1 answer
  • What is online school like 6 sentences
    12·1 answer
  • Digital communications describes a process in which two or more computers or devices transfer ____, ____ and instructions.
    12·1 answer
  • Cnt115-02* which of the following is a private ip address and can't be routed across the internet?
    12·1 answer
  • B. List any four major drawbacks of the first generation computer​
    10·1 answer
  • Which coding term means to carry out a series of steps one after another?
    7·2 answers
  • ! (( i &gt; ( f + 1)) es verdadero o falso segun la logica de programación.
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!