title: Loop over word and extract bigram
body: <p>I would like to extract every single bigram from a given word and put in a text file.</p>
  
  <p>For example:</p>
  
  <pre><code>apple      --&gt;       ap pp pl le
  president  --&gt;       pr re es si id de en nt
  </code></pre>
  
  <p>I found similar work using awk and word but nothing about words.</p>
  
  <p>I just found this code:</p>
  
  <pre><code>sed 's/\(.\{2\}\)/\1 /g' 
  </code></pre>
  
  <p>but it's working with a window size of 2.</p>
  
  <p>So, for example:</p>
  
  <pre><code>apple      --&gt;      ap pl le
  </code></pre>
  
  <p>Thanks for help</p>
  
  <pre><code>sed 's/\(.\{2\}\)/\1 /g' 
  </code></pre>
  
  <p>The expected result is a string of bigram with a window size of 1.</p>