How To: Determine BMI Level in C Programming

HOW TO DETERMINE BMI LEVEL IN C PROGRAMMING



SOURCE CODE!!!

#include <stdio.h>
#include <stdlib.h>

int main()
{
 float w, h, bmi;

 printf("Enter your weight in kg: ");
 scanf("%f", &w);
 printf("Enter your height in meter: ");
 scanf("%f", &h);

 bmi=w/(h*h);

 if(bmi<18.5)
  printf("Underweight");
  else if((bmi>18.5)&&(bmi<24.9))
  printf("Normal");
  else if((bmi>24.9)&&(bmi<29.9))
  printf("Overweight");
  else if(bmi>30)
  printf("Obesity");

 return 0;
}



Feel free to visit my YouTube channel: Four For Fighting

Comments

Popular posts from this blog