Discuss / Python / 呃,签到?

呃,签到?

Topic source
#judgement
# if condition :
# elif condition :
# else:

ID=input('input your ID\n')
height=float(input('input the height\n'))
weight=float(input('input the weight\n'))
BMI=weight/height**2

print('%s , your height is %.2f , your weight is %.2f , your BMI is %.2f .' %(ID,height,weight,BMI))
if BMI<18.5 :
    print('your body is too light\n')
elif BMI<25 :
    print('your body is normal\n')
elif BMI<28:
    print('your body is little heavier\n')
elif BMI<32:
    print('your body is obesed\n')
else :
    print('die\n')

    print('end of the result\n')

  • 1

Reply