+ 3
Need suggestions what improvements can I do in it
https://sololearn.com/compiler-playground/ckPS1kCBag8I/?ref=app
8 odpowiedzi
+ 5
The upper thresholds are off by 0.1. Example: If the BMI is 24.91, mistakenly it would be classified as overweight whereas it is still in the normal range.
Instead of 24.9 annd 29.9, it should compare with 25 and 30.
elif bmi_calc < 25:
...
elif bmi_calc < 30:
...
https://www.cdc.gov/obesity/basics/adult-defining.html
+ 5
FREEZO
You don't have to write input("").
Instead you can just write input() because the argument of the input function is optional.
+ 3
The Q&A form isn’t really for general code review, more for solving specific problems. I decided to look at it anyway, though, and I don’t see any immediate flaws. :-)
+ 3
meter_to_centimeter should be centimeter_to_meter
because you are asking for cm, and want to convert it
why are you using empty print statements? you can use:
print("BMI calculator\n\n")
print(f"Your BMI is: {bmi}\n")
print("You ... \n")
and you can create try-except block as well (with a while loop; if the user does not enter a number...)
+ 2
🥲some peoples are asking questions from out of the coding and they are getting their answers :(
+ 2
Mihaly Nyilas Thank you❤️
+ 2
Brian thank you🌹
+ 1
Niels F 🇩🇪 <html challenger> I,am a noob for real :(