title: Remembering the search patterns in unix shell scripting
body: <p>Am trying to understand the "remembering the search patterns in shell script". Could not able to understand the differences between the mentioned below.</p>
  
  <p><strong><code>$ echo abcd123 | sed 's:\([a-z]*\)\([0-9]\):\2 \1:'</code></strong></p>
  
  <p>1 abcd23</p>
  
  <p><strong><code>$ echo abcd123 | sed 's:\([a-z]*\)\([0-9]\).*:\2 \1:'</code></strong></p>
  
  <p>1 abcd</p>
  
  <p><strong><code>$ echo abcd123 | sed 's:\([a-z]*\).*\([0-9]\).*:\2 \1:'</code></strong></p>
  
  <p>3 abcd</p>