title: Performance effect of using print statements in Python script
body: <p>I have a Python script that process a huge text file (with around 4 millon lines) and writes the data into two separate files.</p>
  
  <p>I have added a print statement, which outputs a string for every line for debugging. I want to know how bad it could be from the performance perspective?</p>
  
  <p>If it is going to very bad, I can remove the debugging line.</p>
  
  <p><strong>Edit</strong></p>
  
  <p>It turns out that having a print statement for every line in a file with 4 million lines is increasing the time way too much.   </p>