title: Appending to a dictionary of lists elements from a nested list in order
body: <p>I've created a dictionary with keys that represent relative distances and values that are empty lists. I would like to populate these values--empty lists--with entries from a nested list that are the values of the relative distances. My problem is that when I populate the values of the dictionary, its entries are not being filled in the order in which they appear in the nested list.</p>
  
  <p>This is the closest I've gotten to solving the problem:</p>
  
  <pre><code>relDistDic = { 'a':[], 'b': [] } # dictionary with relative distances
  
  relDist = [[1,2,3], [4,5,6], [7,8,9], [10,11,12] ] #nested list with dstncs
  
  for v in relDistDic.values():
      for element in relDist:
          if len(v) &lt; 2 :
              v.append(element)
  </code></pre>
  
  <p>I would like to get the following output:</p>
  
  <pre><code>{ 'a':[[1,2,3], [4,5,6]], 'b': [[7,8,9], [10,11,12]] }
  </code></pre>
  
  <p>But instead I am getting this:</p>
  
  <pre><code>{ 'a':[[1,2,3], [4,5,6]], 'b': [[1,2,3], [4,5,6]] }
  </code></pre>
  
  <p>Any help or comments are greatly appreciated, thanks!</p>