Why is my dictionary value changing without me telling it to, and how do I stop it? : <p>This is my sample code:</p>

<pre><code>dict1 = {'a': 5, 'b': 6, 'c': 7}
dict2 = dict1
for i in dict1:
    dict1[i] += 5
print dict1
print dict2
</code></pre>

<p>Output looks like this:</p>

<pre><code>{'a': 10, 'c': 12, 'b': 11}
{'a': 10, 'c': 12, 'b': 11}
</code></pre>

<p>Why is dict2 changing without me telling it to?</p>

<p>Python 2.7.10 on GCC 4.8.2 Linux.</p>

<p>Also tried on 2.7.12 on GCC 5.4.0, same result.</p>
