title: scanf won't ask for input the second time
body: <pre><code>#include "stdio.h"
  
  int main(void)
  {
  
       int order, nextp, N=3;
       char cont;
       nextp = 0;
       printf("\nShould we continue (y or n): ");
       scanf("%c", &amp;cont);
       if (cont != 'y') return;
       for(; nextp &lt; N; nextp++)
       {
          printf("Enter order number: ");
          scanf("%d", &amp;order);
          printf("you have entered %d\n", order);
          printf("okay now continue with cont\n");
  
  
          printf("enter cont y or n: ");
          scanf("%c", &amp;cont);
          if (cont != 'y')
          {
              printf("\nnot equal to y\n");
              break;
          }
          printf("after intepreting t[0]");
        }
  
     return 0;
  }
  </code></pre>
  
  <p>The output looks like this</p>
  
  <pre><code>Should we continue (y or n): y
  Enter order number: 45
  you have entered 45
  okay now continue with cont
  enter cont y or n: 
  not equal to y
  </code></pre>
  
  <p>The second input was skipped. Why?</p>