+ 1

What is wrong?

The first two test case show the output properly but the remaining three test cases, which I cannot see the results of, are showing fails so I can't even speculate on what inputs are being used. https://code.sololearn.com/cAGmNmOTQWYl/?ref=app

8th Sep 2021, 5:40 PM
Justice Brinston
Justice Brinston - avatar
6 odpowiedzi
+ 1
elif bmi <= 18.5 and bmi > 25: can't execute because a number can't be bigger than 25 and less than 18 at the same time same for elif bmi <=25 and bmi >30
8th Sep 2021, 5:49 PM
jsjsshjsjs
+ 1
instead, replace elif bmi <=25 and bmi >30 with elif bmi >=25 and bmi <30 and elif bmi <= 18.5 and bmi > 25 with elif bmi >= 18.5 and bmi < 25
8th Sep 2021, 5:50 PM
jsjsshjsjs
+ 1
Read carefully ... and less than 25 Your code: bmi > 25 ...and less than 30 Your code: bmi > 30
8th Sep 2021, 5:51 PM
Coding Cat
Coding Cat - avatar
+ 1
less than 25: bmi<25
8th Sep 2021, 5:52 PM
jsjsshjsjs
+ 1
the < sign is the sign to check if the value at the left is lower than value at the right
8th Sep 2021, 5:52 PM
jsjsshjsjs
0
Wow, just wow, so I put the wrong sign. What a rookie mistake lol thanks guys
8th Sep 2021, 6:11 PM
Justice Brinston
Justice Brinston - avatar