title: How to print the progress of a list comprehension in python?
body: <p>In my method i have to return a list within a list. I would like to have a list comprehension, because of the performance since the list takes about 5 minutes to create.</p>
  
  <pre><code>[[token.text for token in document] for document in doc_collection]
  </code></pre>
  
  <p>Is there a possibility to print out the progress, in which document the create-process currently are? Something like that:</p>
  
  <pre><code>[[token.text for token in document] 
    and print(progress) for progress, document in enumerate(doc_collection)]
  </code></pre>
  
  <p>Thanks for your help!</p>