title: Why doesn't out-of-scope variables still work in python?
body: <pre><code>for i in range(10):
      s = 'a'
      print(i)
  print(s)
  </code></pre>
  <p>It prints out 'a' although s is out of scope. This makes programming more difficult for such cases because when you are referencing 's' outside of the for loop, you assume that 's' is defined outside of the loop.</p>
  <p>Is this normal in Python?</p>