What is wrong with my attempt to do a string replace operation in Python?
<p>What am I doing wrong here?</p>

<pre><code>import re
x = "The sky is red"
r = re.compile ("red")
y = r.sub(x, "blue")
print x  # Prints "The sky is red"
print y  # Prints "blue"
</code></pre>

<p>How do i get it to print "The sky is blue"?</p>
