title: Converting an array of wrappers to an array of primitives
body: <p>If I have an array of instances of primitive wrapper classes, how can I obtain an array of their respective primitives?</p>
  
  <pre><code>Object toPrimitiveArray(Object[] wrappedArray) {
      return ?;
  }
  
  Object primitiveArray = toPrimitiveArray(new Integer[] { 1, 2, 3 });
  </code></pre>
  
  <p>In the above example, I'd like <code>toPrimitiveArray()</code> to return an <code>int[]</code> containing the <code>int</code> values <code>1</code>, <code>2</code>, and <code>3</code>.</p>