# include using namespace std; double weight, height; int age; double hat(double height_par, double weight_par); double jacket(double height_par, double weight_par, int age_par); double waist(double weight_par, int age_par); int main() { char again; do { int feet, inches, total_height; double hat_size, jacket_size, waist_size; cout << " How heavy are you?" << endl; cin >> weight; cout << "How tall are you in feet and inches?" << endl << " First how many feet tall are you?" << endl; cin >> feet; cout << "How many inches are left?" << endl; cin >> inches; cout << " You are " << feet << "feet and " << inches << "tall."<< endl; total_height = (feet * 12) + inches; cout << total_height << endl; cout << "How old are you?" << endl; cin >> age; cout << "You are " << age << " years old." << endl; hat_size = hat(total_height, weight); jacket_size = jacket(total_height, weight, age); waist_size = waist(weight, age); cout << "You have a hat size of " << hat_size << "."<< endl; cout << "You have a Jacket size of " << jacket_size << "." << endl; cout << "You have a waist size of " << waist_size << "." << endl; cout << "Woud you like to make another measurement? Y = yes N = no"; cin >> again; } while ((again == 'Y') || (again == 'y')); cout << "Have a nice day."; return(0); } double hat(double height_par, double weight_par) { double hat; hat = (weight_par / height_par) * 2.9; return(hat); } double jacket(double height_par, double weight_par, int age_par) { double jacket; int multiple; jacket = (height_par * weight_par) / 288; if (age_par > 30) { multiple = (age - 30) / 10; jacket = jacket + (multiple * .125); return (jacket); } else return(jacket); } double waist(double weight_par, int age_par) { double waist; int multiple; waist = weight_par / 5.7; if (age > 28) { multiple = (age - 28) / 2; waist = waist + (multiple * .1); return (waist); } else return (waist); }