##Example 1 def getCategory(pounds,feet,inches): ins = (feet*12) + inches result = (pounds*703) / ins**2 if result >= 30: result = "obese" elif result < 30 and result >= 25: result = "overweight" elif result < 25 and result >=18.5: result = "normal" elif result < 18.5: result = "underweight" return result ######################### ##Example 2 def getCategory (weight,height,inches): wei = weight * 703 heights = height*12 + inches bmi = wei/ heights**2 if bmi< 18.5: return ("underweight") if bmi >= 18.5 and bmi < 25: return ("normal") if bmi >= 25 and bmi < 30: return ("overweight") if bmi>= 30: return ("obese") ######################### ##Example 3 def getCategory(weight, height_feet, height_in): height = (height_feet*12)+height_in bmi = (weight*703)/height**2 if bmi < 18.5: bmi = underweight answer = underweight elif bmi >= 18.5 and bmi < 25: bmi = normal answer = normal elif bmi >= 25 and bmi <= 30: answer = overweight else: answer = obese return answer