title: Regex to extract substring, returning 2 results for some reason
body: <p>I need to do a lot of regex things in javascript but am having some issues with the syntax and I can't seem to find a definitive resource on this.. for some reason when I do:</p>
  
  <pre><code>var tesst = "afskfsd33j"
  var test = tesst.match(/a(.*)j/);
  alert (test)
  </code></pre>
  
  <p>it shows </p>
  
  <pre><code>"afskfsd33j, fskfsd33"
  </code></pre>
  
  <p>I'm not sure why its giving this output of original and the matched string, I am wondering how I can get it to just give the match (essentially extracting the part I want from the original string)</p>
  
  <p>Thanks for any advice</p>