title: Java - Sort a multidimensional double array
body: <p>I have a multidimensional array with double values that I would like to sort.. </p>
  
  <pre><code>//declare array    
  standingsB = new Double[10][2];
  
  //populate array from the temparray created during read from file
  arryLgt = 0;
          for (int row = 0; row &lt; standingsB.length; row++){
  
              for (int column = 0; column &lt; standingsB[row].length; column++) {
  
  
                  standingsB[row][column] = Double.parseDouble(tempStandingsArray[arryLgt]);
                  arryLgt = arryLgt + 1;
              }
          }
  </code></pre>
  
  <p>The array has values such as [1.5,7.0] [4.2,4.0] etc... </p>
  
  <p>For the next part I don't really know how it works but from reading other articles here this is the best as I can copy without knowledge </p>
  
  <pre><code>Arrays.sort(standingsB, new Comparator&lt;Double[]&gt;() {
              @Override
              public int compare(Double[] s1, Double[] s2) {
                  compare(s1, s2);
              }
          });
  </code></pre>
  
  <p>The above fails to compile (with missing return statement) which is to be expected as I have no idea on how to use the Arrays.sort with a comparator.  But I'm not even sure if I'm on the right page being as new to Java (and programing in general) as I am.</p>
  
  <p>Thanks for looking!</p>