title: How to sort array by first item in subarray
body: <p>I have an array with subarrays and wish to sort numerically and descending by the first item in the subarrays.  So for example, I wish to take the following array"</p>
  
  <pre><code>array = [[2,text],[5,text],[1,text]]
  </code></pre>
  
  <p>and sort it to become</p>
  
  <pre><code>array = [[5,text],[2,text],[1,text]]
  </code></pre>
  
  <p>Is there any simple function to use?  Thanks!</p>