change value when python is in infinite loop
<p>Can this be done in python?
Start by print an infinite loop and changing values in between loops.</p>

<pre><code>x = 5
while ( true ):
  print x
x = 3 # regain control of the interpreter and set to new value
</code></pre>

<p>expected output:</p>

<pre><code>5
5
5
......
3
3
3
</code></pre>
