title: how to convert array of arrays (from reading a csv file) into a hash
body: <p>After reading a csv file, I have this data structure:</p>
  
  <pre><code>[["name1 | value1 | value2 | value3 | value4 "],
   ["name2 | value1 | value2 | value3 | value4 "],...]
  </code></pre>
  
  <p>I need to convert this to a Hash, like this:</p>
  
  <pre><code>{"name1" =&gt; "value1 | value2 | value3 | value4", 
   "name2" =&gt; "value1 | value2 | value3 | value4",...}
  </code></pre>
  
  <p>Or, better yet:</p>
  
  <pre><code>{"name1" =&gt; ["value1","value2","value3","value4"],
   "name2" =&gt; ["value1","value2","value3","value4"],...}
  </code></pre>
  
  <p>I have found numerous methods for converting arrays of arrays to hashes, but none that take the first element in the inner array and use it as the key of the Hash.  </p>
  
  <p>Can anyone suggest an elegant solution?</p>