title: printf displays a different value
body: <p>I've got a variable i that is initialized to 1, when I want to display it, it displays 6421788 instead of 1.</p>
  <pre><code>int i = 1;
  
      printf(&quot;WELCOME: OUR AVAILABLE TRIPS:\n&quot;);//displaying trips
      while(fgets(trip,sizeof(trip),StrdFile) != NULL)
          {
          printf(&quot;%i.&quot;,&amp;i);//the problem
          printf(&quot;%s\n&quot;,trip);
          i++;
          }
  </code></pre>
  <p>This is the part of the code that must be the problem. The display need to be :</p>
  <pre><code>1.\*info*
  2.\*info*
  </code></pre>
  <p>but what I get is</p>
  <pre><code>6421788.\*info*
  6421788.\*info*
  </code></pre>
  <p>also, I checked the value of i in the debugger and it's correct.</p>