title: Cut / echo inside bash
body: <p>Im confused with how the following cut works in the bash script.</p>
  
  <p>Sample of <code>file.csv</code>:</p>
  
  <pre><code>#10.10.10.10;28;9.10.10.10: up;Something ;More random spaces
  </code></pre>
  
  <p>My script:</p>
  
  <pre><code>#!/bin/bash
  
  csv_file="file.csv"
  
  locations=( $( cut -d';' -f5 $csv_file ) )
  
  for ((i=0; i &lt; ${#locations[@]}; i++))
  do
     echo "${locations[$i]}"
  done
  </code></pre>
  
  <p>The result of the script is:</p>
  
  <pre><code>More
  random
  spaces
  </code></pre>
  
  <p>When I just copy and paste the cut in my CLI without any echos or variables the cut works as I´d expect and prints:</p>
  
  <pre><code>More random spaces
  </code></pre>
  
  <p>I am sure it´s some bracket or quote problem, but I just can't figure it out.</p>