title: Python's print function that flushes the buffer when it's called?
body: <blockquote>
    <p><strong>Possible Duplicates:</strong><br>
    <a href="https://stackoverflow.com/questions/230751/how-to-flush-output-of-python-print">How to flush output of Python print?</a><br>
    <a href="https://stackoverflow.com/questions/881696/unbuffered-stdout-in-python-as-in-python-u-from-within-the-program">unbuffered stdout in python (as in python -u) from within the program</a>  </p>
  </blockquote>
  
  
  
  <p>I have the following code to flushing out the output buffer. </p>
  
  <pre><code>print 'return 1'
  sys.stdout.flush()
  </code></pre>
  
  <p>Can I setup the print function so that it automatically flushes the buffer when it's called?</p>