title: bash awk split string into array
body: <p>I am using awk to split a string into array using a specific delimiter. Now, I want to perform some operation on each element of the array.</p>
  
  <p>I am able to extract a single element like this:</p>
  
  <pre><code>#! /bin/bash
  
  b=12:34:56
  a=`echo $b | awk '{split($0,numbers,":"); print numbers[1]}'`
  echo $a
  </code></pre>
  
  <p>I want to do something like this:</p>
  
  <pre><code>#! /bin/bash
  
  b=12:34:56
  `echo $b | awk '{split($0,numbers,":");}'`
  for(i=0;i&lt;length(numbers);i++)
  {
     // perform some operation using numbers[i]
  }
  </code></pre>
  
  <p>how would I do something like this in bash scripting?</p>