(Please try to write the program using codes that are not advanced so I can foll
ID: 3617200 • Letter: #
Question
(Please try to write the program using codes that are not advanced so I can follow it.) Write a program that asks for the users height (in inches), weight (in pounds), and age, and then computes clothing sizes according to the formulas: Hat size = weight / height *2.9 Jacket size (chest in inches) = weight * height / 288 and then adjusted by adding 1 / 8 of an inch for each 10 years over age 30. (Note that adjustments only takes place after a full 10 years. So. there is no adjustments for ages 30 through 39. but 1/ 8 of an inch is added for age 40.) Waist in inches = weight / 5.7 and then adjusted by adding 1/ 10 of 3n inch for each 2 years over 28. (Note that the adjustment only takes place after a full 2 years. So, there is no adjustments for age 29, but 1 / 10 of 3n inch is added for age 30.) Use functions for each calculation. Your program should allow the user to repeat this calculation as often as the user wishes. (Note: No infinite loops.)Explanation / Answer
please rate - thanks as per your request #include using namespace std; double hatsize(int,int); double waistsize(int,int); double jacketsize(int,int,int); int main() {int ht,wt,age; double hat,jacket,waist; coutht; while(ht>0) {coutwt; coutage; hat=hatsize(wt,ht); jacket=jacketsize(wt,ht,age); waist=waistsize(wt,age); coutRelated Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.