title: Need help writing a BMI calculator in C
body: <p>I am attempting to write a program that will take a user's input of weight and height and then return a BMI value and tell the user if they are under/over or normal weight. The code compiles with no errors, however no matter what numbers I input for weight and height, the result is always "You have a BMI of 0 and your weight status is overweight". Is there something wrong with my code or is my math just incorrect?</p>
  
  <pre><code>#include &lt;stdio.h&gt;
  
  int main()
  {
      double wt_lb, ht_in, bmi, ht_ft;
  
      printf("Please enter your weight in whole pounds: ");
      scanf("%lf", &amp;wt_lb);
      printf("Please enter your height in whole inches: ");
      scanf("%lf", &amp;ht_in);
  
      ht_ft = ht_in/12;
      bmi = (703*wt_lb)/(ht_ft*ht_ft);
  
      if (bmi &lt; 18.5) {
              printf("You have a BMI of %.lf, and your weight status is underweight\n" &amp;bmi);
      } else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt; 25) {
          printf("You have a BMI of %.lf, and your weight status is normal\n", &amp;bmi);
      } else {
          printf("You have a BMI of %.lf, and your weight status is overweight\n", &amp;bmi);
      }
  }
  </code></pre>