title: Global variables and coding style recommendations
body: <p>This question is quite general but it's more for me to understand good coding practices in python...</p>
  
  <p>I'd like to define a constant that I can use inside in any function without having to pass it as argument, and without the need to change it anywhere after its declared - maybe it'd be nice to make it impossible to change but not sure if i can do that.</p>
  
  <p>What'd be the best way to do this, in terms of programming style (coding, name convention, etc.)</p>
  
  <p>I.e.,
  GLOBAL_CONSTANT='this_variable_will_not_be_changed'</p>
  
  <p>My python code would have this form, is it good style as well?</p>
  
  <pre><code>#!/usr/bin/env python
  
  import sys
  import os
  
  GLOBAL_CONSTANT='this_variable_will_not_be_changed'
  
  def test():
      print GLOBAL_CONSTANT
      return 0
  
  def main():
      test()
      return 0
  
  if __name__ == "__main__":
      main()
  </code></pre>