Programming Examples

Python program to calculate body mass index of a person


Python program to calculate (BMI) body mass index of a person

Body Mass Index is a simple calculation using a person's height and weight. The formula is BMI=kg/m^2 where kg is a person's weight in kilogram and m^2 is the height in meter squared.

Solution

weight=float(input("Enter the weight of person in KG : "))
height=float(input("Enter the height of person in meter : "))
bmi=weight/(height*height)
print("BMI of person is : ",bmi)
Output

Enter the weight of person in KG : 60

Enter the height of person in meter : 1.6

BMI of person is :  23.437499999999996

Online Exam Quiz for One day Exam Online Typing Test CCC Online Test 2026 Best Computer Training Institute in Prayagraj (Allahabad) Best Java Training Institute in Prayagraj (Allahabad) Best Python Training Institute in Prayagraj (Allahabad) O Level Online Test in Hindi Best Website and Software Company in Allahabad