Discuss / Python / 练习

练习

Topic source

-- coding: utf-8 --

height = 1.8 weight = 80.5 BMI = weight/(height*height) if BMI >=32 : print(u'严重肥胖') elif 28<= BMI <32: print(u'肥胖') elif 25<= BMI <28: print(u'过重') elif 18.5<= BMI <25: print(u'正常') else: print(u'过轻')


  • 1

Reply