What’s the problem | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

What’s the problem

A program to calculate BMI: weight = int(input()) Height = float(input()) BMI = weight / Height ** 2 if (BMI < 18.5) : print ("Underweight") elif(BMI >= 18.5 < 25): print ("Normal") elif(BMI >= 25 < 30): print ("Overweight") if (BMI >= 30): print ("Obesity")

16th Nov 2021, 1:46 PM
Joudy Ramy
Joudy Ramy - avatar
2 Answers
+ 1
Conditions of ellif block is in Incorrect way .. Ex: correct way (18.5 <= BMI <25) #means BMI is in between 18.5 and 25 ?
16th Nov 2021, 1:56 PM
Jayakrishna 🇮🇳