using zip function and getting errors using getcontext().prec =2
<p>I am experiencing a problem when trying to use the getcontext().prec = 2 function, trying to get decimal results with only 2 decimals. I have experimented with several variations, but don't know why I can't transform float to string inside one of my lists. I am new using Python (2.6), and have not been able to find a solution for this. Thanks in advance for any help.</p>

<pre><code>from __future__ import division
from decimal import *

getcontext().prec = 2

list_a = ['abc','def','ghi']
list_b = [123, 534, 345]
list_c = [Decimal(str(1/6)), Decimal(str(1/1234)), Decimal(str(2/9))]

for r,c,p in zip(list_a, list_b, list_c):
  print '{0} goes with {1} and with {2}%.'.format(r,c,p)
</code></pre>

<p>Returns</p>

<pre><code>SyntaxError: Invalid syntax
</code></pre>

<p>If  I eliminate the str() from the print line, the results are printed, but w/o constraints in the number of decimals. If I use Decimal() - w/o using str first, I get </p>

<pre><code>'first convert the float to a string'. 
</code></pre>

<p>Any insights? 
Cheers</p>
