#include <iostream>
#include <iomanip>
#include <string>

using namespace std;

double getBMI (int, int);
string getWeightStatus(double);

int main()
{
	int weight, height;
	double bmi;
	
	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) << endl;
	
	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
	{
		weightStatus = "underweight";
	}
	
	return weightStatus;
}
