title: Java array after loop
body: <p>can you explain to me how  <code>a[i] = a[a[i]]</code> works?</p>
  
  <pre><code>int[] a = new int[10]
  for(int i =0; i &lt; 10; i++)
      a[i] = 9 - i
  
  for(int i =0; i &lt; 10; i++)
      a[i] = a[a[i]]
  
  for(int i =0; i &lt; 10; i++)
  </code></pre>