#include <iostream>
#include <cmath>
using namespace std;
int main()
{
double height, weight;
double BMI;
cout << "Please key in your height.(cm)" <<endl ;
cin >> height ;
height = height * 0.01 ;
cout << "Please key in your weight.(kg)" <<endl ;
cin >> weight ;
BMI = weight / (height*height);
cout << "Your BMI is";
cout << BMI <<endl;
return 0;
} |