Loop over list of dictionaries and within list values
<p>Suppose I have a list of two dictionaries:</p>

<pre><code>iter_list = [{0: [2, 1, 3], 
              1: [3, 2, 1], 
              2: [1, 2, 3], 
              3: [2, 3, 1], 
              4: [1, 2, 3], 
              5: [2, 3, 1]},
             {0: [2, 3, 1], 
              1: [1, 2, 3], 
              2: [1, 2, 3], 
              3: [1, 2, 3], 
              4: [2, 3, 1], 
              5: [1, 3, 2]}]
</code></pre>

<p>Each dictionary has 6 keys numbered 0 through 5.
I would like to loop through each dictionary one at a time in the order of the key and have the output be a pair with the key (ordered by the key value) and the first value of the corresponding list, the first value corresponding with the second key etc. followed by the key and the second value etc.  Hopefully the example output will clarify:</p>

<pre><code>0 2
1 3
2 1
3 2
4 1
5 2
0 1
1 2
2 2
3 3
4 2
5 3
0 3
1 1
2 3
3 1
4 3
5 1
0 2 //2nd dictionary iteration 
1 1
2 1
3 1
4 2
5 1
0 3 
1 2
2 2
3 2
4 3
5 3
0 1
1 3
2 3
3 3
4 1
5 2
</code></pre>

<p>I've only been able to figure out how to loop through the first position of the first dictionary, but can't figure out how to use the [0] as an iteration variable to go through all positions in the value lists before moving on to the next dictionary.  </p>

<pre><code>for i in iter_list:
    for key, value in i.iteritems():
            print key, value[0]
</code></pre>

<p>Any help is greatly appreciated! Thanks!</p>