Discuss / Python / 作业

作业

Topic source

Pain德拉贡

#1 Created at ... [Delete] [Delete and Lock User]

w = float(input('weight:'))

h = float(input('height:'))

s = w/(h*h)

BMI = float(s)

if BMI < 18.5:

    print('you are too light')

elif 18.5 < BMI <25:

    print('you have a healthy weight')

elif 25 < BMI < 28:

    print('you are a little heavy')

elif 28 < BMI < 32:

    print('you are too fat')

elif BMI > 32:

    print("you are severely fat")


  • 1

Reply