title: how to get string between two strings
body: <p>so for example, I have a string like this:</p>
  
  <pre><code>f=awerawet1351&amp;q=aet12462awera&amp;l=3ewar462&amp;h=awiejt361
  </code></pre>
  
  <p>and I wanna grab the substring between "q=" and "&amp;", which is "aet12462awera" or "q=aet12462awera" is also fine. 
  I tried to use<code>awk -F'&amp;'</code> , but the thing is, the position for "q="string is not fixed. Sometimes, I will have </p>
  
  <pre><code>f= .... &amp; l=.... &amp;q=....&amp; h=....
  </code></pre>
  
  <p>so I can't use <code>awk -F'&amp;' '{print $2}'</code> to get the result.</p>
  
  <p>Is there anyway for me to use unix command to get it?
  Thanks!</p>