title: Creating a dictionary from a CSV file
body: <p>I am trying to take input from a CSV file and then push it into a dictionary format (I am using Python 3.x).</p>
  <p>I use the code below to read in the CSV file and that works:</p>
  <pre><code>import csv
  
  reader = csv.reader(open('C:\\Users\\Chris\\Desktop\\test.csv'), delimiter=',', quotechar='|')
  
  for row in reader:
      print(', '.join(row))
  </code></pre>
  <p>But now I want to place the results into a dictionary.  I would like the first row of the CSV file to be used as the &quot;key&quot; field for the dictionary with the subsequent rows in the CSV file filling out the data portion.</p>
  <p>Sample data:</p>
  <pre class="lang-none prettyprint-override"><code>     Date        First Name     Last Name     Score
  12/28/2012 15:15        John          Smith        20
  12/29/2012 15:15        Alex          Jones        38
  12/30/2012 15:15      Michael       Carpenter      25
  </code></pre>
  <p>How can I get the dictionary to work?</p>