#include<iostream>
#include <string>
#include<iomanip>

using namespace std;

double getBMI(int, int);
string getWeightStatus(double);

int main()
{
	int weight, height;
	double BMI;
	string weightStatus;
	
	
	cout << "Enter weight in KG: ";
	cin >> weight;
	
	cout << "Enter height in Inch: ";
	cin >> height;
	
	BMI = getBMI(weight, height);
	
	cout << fixed << setprecision(1) << "Your BMI: " << BMI << endl;
	
	
	cout << " BMI status: " << getWeightStatus(BMI);
	
	return 0;
}

double getBMI (int weight, int height)
{
	double heightInMeter = height*0.0254;
	return weight / (heightInMeter*heightInMeter);
	
}

string getWeightStatus (double BMI)
{
	string weightStatus = " ";
	
	if ( BMI >= 30 )
	{
		weightStatus = "obese";
	}
	else if ( BMI >=25 && BMI <30)
	{
		weightStatus = " overweight ";
	}
	else if ( BMI >= 18.5 && BMI < 25)
	{
		weightStatus = " normal weight";
	}
	else if ( BMI < 18.5)
	{
		weightStatus = " underweight";
	}
	return weightStatus;
}

