title: Reversing an Array in Java
body: <p>If I have an array like this:</p>
  
  <pre><code>1 4 9 16 9 7 4 9 11 
  </code></pre>
  
  <p>What is the best way to reverse the array so that it looks like this:</p>
  
  <pre><code>11 9 4 7 9 16 9 4 1 
  </code></pre>
  
  <p>I have the code below, but I feel it is a little tedious:</p>
  
  <pre><code>public int[] reverse3(int[] nums) {
      return new int[] { nums[8], nums[7], nums[6], nums[5], num[4],
                         nums[3], nums[2], nums[1], nums[0] };
  }
  </code></pre>
  
  <p>Is there a simpler way?</p>