title: Javascript: sort 2D array at first by second column desc, then by first column asc
body: <p>I have so called 2D array called myarr with dozen rows and 2 column. Its contents is as follows:</p>
  
  <pre><code>myarr[0][0]='John'
  myarr[0][1]=48
  myarr[1][0]='Ann'
  myarr[1][1]=36
  myarr[2][0]='Sean'
  myarr[2][1]=18
  ...
  </code></pre>
  
  <p>And I would like to sort it by second column first descending, then by first column ascending, like this one:</p>
  
  <pre><code>John 48
  Ann 36
  Bob 36
  Carl 36
  Sean 18
  Dean 17 ..
  </code></pre>
  
  <p>By using JavaScript and I tried something like this:</p>
  
  <pre><code>myarr.sort(function(a, b){
      a = a[1]+a[0];
      b = b[1]+b[0];
      return a == b ? 0 : (a &gt; b ? 1 : -1)
  })
  </code></pre>
  
  <p>But this way sort by column 2 asc (0 - 85) then by column 1 asc (A - Z). Where I made error? Thank you.</p>