title: how to use a variable in head function in for loop in unix shell
body: <p>i'm very new, and am working on variables. </p>
  
  <p>i wonder how can I use a variable in head function</p>
  
  <p>for example,</p>
  
  <pre><code>for ((i=0; i&lt;5; i++))
  head -((1+i)) test.txt
  </code></pre>
  
  <p>but it displays an error. how can i fix this?</p>