title: C programming elementary problem
body: <pre><code>#include &lt;stdio.h&gt;
  #include &lt;math.h&gt;
  
  
  int main (void)
  {
      float inches;
      printf("Enter the number of inches\n");
      scanf("%f\n",&amp;inches);
  
  
      float feet;
      float cm;
      float yards;
      float meter;
  
      feet = 12 * inches;
      cm = 2.54 * inches;
      yards = 36 * inches;
      meter = 39.37 * inches;
  
      printf("Amount in feet: %f\n", &amp;feet);
      printf("Amount in cm:   %f\n", &amp;cm);
      printf("Amount in yards: %f\n", &amp;yards);
      printf("Amount in meters: %f\n", &amp;meter);
  
  
  
  
     getchar();
  
     return 0;
  
  }
  </code></pre>
  
  <p>I'm using Dev c++</p>
  
  <p>Is the problem i'm problem I'm working on in C. Basically enter in a number in inches then print amount in cm,yards,meters and feet. This is giving me 0.0000 or something for all of them or actually the time it is up. I can't keep the screen up and I thought that was the purpose of getchar() but I must have been mistaken. Any help is great. Thanks!</p>
  
  <p><strong>EDIT 1</strong></p>
  
  <p>What about as far as keeping dev c++ on the screen instead of closing out after I put stuff in? I am also having to put 2 values in before it returns in anything when the screen pops up? Why??</p>