print("Welcome to BMI calculator 2.O") weight = float(input("Please enter your weight in kg:\n")) height = float(input("Please enter your height in m:\n")) BMI = round(weight / height ** 2, 2) if BMI < 18.5: print(f"Your BMI is {BMI}, you are underweight") elif (BMI > 18.5) and (BMI < 25): print(f"Your BMI is {BMI}, you have a normal weight") elif (BMI > 25) and (BMI < 30): print(f"Your BMI is {BMI}, You are slightly overweight") elif (BMI > 30) and (BMI < 35): print(f"You BMI is {BMI}, You are clinically obese") else: print(f"Your BMI is {BMI}, you are clinically obese")
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter