title: Sort Javascript array based on a substring in the array element
body: <pre><code>var arr = ["This is three", "This is four", "This is one", "This is two", ...];
  </code></pre>
  
  <p>If I have an array like the one shown above, and I need to sort the array based on the substring value in the strings - i.e one, two, three.., 
  What is the best approach to the problem? </p>
  
  <p>My final result should be </p>
  
  <pre><code>var sortedArr = ["This is one", "This is two", "This is three", "This is four", ...];
  </code></pre>