Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- File "bmi.py", line 1, in <module>
- while true:
- NameError: name 'true' is not defined
- while true:
- height=input("身長(m)?:")
- if len(height)==0:
- break
- height=float(height)
- weight=float(input("体重(kg)?:"))
- bmi=weight/pow(height,2)
- print("BMI値は{:.1f}です。".format(bmi))
- if bmi<18.5:
- print("Mr.ガリガリ君")
- elif 18.5<=bmi<25.0:
- print("中肉中背THEふつう君")
- elif 25.0<=bmi<30.0:
- print("デブ")
- else:
- print("末期のデブ")
Add Comment
Please, Sign In to add comment