title: Java: How to sort two corresponding arrays?
body: <p>I have two arrays:</p>
  
  <pre><code>First array:
  25, 20, 50, 30, 12, 11...
  
  Second Array: 
  New York, New Jersey, Detroit, Atlanta, Chicago, Los Angeles
  </code></pre>
  
  <p>Every two cities from the second array correspond to one value from the first. </p>
  
  <p>Example: New York and New Jersey would correspond to 25, Detroit and Atlanta would correspond to 20 and so on. </p>
  
  <p>I want to reorder the first Array's numbers in descending order (50, 30, 25, 20...), but I also want the cities of the second array to be shifted accordingly so that they have the same value before and after the sort. </p>
  
  <p>How do I accomplish this task? (I can use either an ArrayList or an Array, whichever works out simpler) </p>