Write a program to calculate the BMI of a person using the
formula BMI = weight/height2.
Answers were Sorted based on User's Feedback
Answer / g.durga
main()
{
float bmi;
int weight,height;
printf(enter weight and height");
scanf("%d%d",&weight,&height);
bmi=weight/height;
print("%f",bmi);
getch();
}
| Is This Answer Correct ? | 12 Yes | 6 No |
Answer / nitin kalambe
void main()
{
float BMI,weight,height;
cout<<"Enter you weight and height"<<endl;
cin>>weight>>height;
BMI=weight/height*height;
cout<<"Your BMI is "<<BMI;
getch();
}
| Is This Answer Correct ? | 7 Yes | 6 No |
Why is main an int?
Why do we use iterators?
What is c++ 11 and c++ 14?
Give an example of run-time polymorphism/virtual functions.
What is c++ and its uses?
Explain what data encapsulation is in c++?
What does asterisk mean in c++?
What does the following do: for(;;) ; a) Illegal b) Loops forever c) Ignored by compiler...not illegal
Declare a class vehicle and make it an abstract data type.
Is facebook written in c++?
What is pointer to member?
What is the identity function in c++? How is it useful?