title: Cannot figure out how to use getchar(); in C
body: <pre><code>#include &lt;stdio.h&gt;
  int main(void)
  
  {
      char F,C;
  
      printf("Do you have a Fever? y/n\n");
      F = getchar();
  
      printf("Do you have a runny nose or cough? y/n\n");
      C = getchar();
  
  
      printf("Here are the results you input:\n");
      printf("Do you have a fever?");
      putchar(F);
  
      printf("\nDo you have a runny nose or cough?");
      putchar(C);
  
      return 0;
  }
  </code></pre>
  
  <p>The code inputs results from first <code>getchar();</code> and then exits without waiting for more input.  Why is that?</p>