title: Initialization before or inside the for loop in Java
body: <p>Please tell me what's the difference of these two snippets of code:</p>
  
  <pre><code>int i = 0;
  for(i; i &lt; test; i++) {...}
  </code></pre>
  
  <p>and</p>
  
  <pre><code>for(int i = 0; i &lt; test; i++) {...}
  </code></pre>
  
  <p>Is there any difference between these ways of initializing the <code>i</code>-increment variable? Does it affect anything or not?</p>