title: How do I perform a memory-efficient array sort in java?
body: <p>I'm wanting to sort a large array of Strings (notably <code>File.list()</code>, which I cannot externalise or reduce further) without using [much] extra memory.</p>
  
  <p><code>Arrays.sort()</code> says it does a merge sort, and wikipedia says that some implementations allocate the size of the original array for storing the sorted output. (This seems to be supported by the <code>System.arraycopy</code> reference in the method).</p>
  
  <p>Is there an in-place sorting algorithm I can use instead which is memory efficient?</p>