title: how to print a increment value using bash
body: <pre><code>for i in $(seq 1 100)
  do
     ADDRESS=$(head -$i "$project_name/address" | tail -1 | cut -f2)
     sed -i.old "20s/.\{60\}/&amp;${ADDRESS}/" "Desktop/lscript.ld"
  done
  </code></pre>
  
  <p>I am using this code according to this:</p>
  
  <pre><code>if [[ i = 1 ]]
  then
      ADDRESS=$(head -1 "$project_name/address" | tail -1 | cut -f2)
  fi
  </code></pre>
  
  <p>will be executed but i want the <code>head</code> value to be incremented by 1 each time.  </p>
  
  <p>When <code>i=1</code> i want <code>head -2</code> to be executed, for <code>i=2</code> i want <code>head -3</code>. How can i do this using Bash?</p>