height = 1.75 weight = 80.5 bmi = weight/(height*height) print('小明的bmi为%.2f' % bmi) if bmi>32: print('severe obesity') elif bmi>28: print('fat') elif bmi>25: print('overweight') elif bmi>18.5: print('normal') else: print('light')
Sign in to make a reply
Myron_W
-- coding: utf-8 --
height = 1.75 weight = 80.5 bmi = weight/(height*height) print('小明的bmi为%.2f' % bmi) if bmi>32: print('severe obesity') elif bmi>28: print('fat') elif bmi>25: print('overweight') elif bmi>18.5: print('normal') else: print('light')