title: Python stop input after empty string is entered
body: <p>Recently I started diving into python a bit, unfortunately I am struggling in the very beginning.
  <strong>What is the best and the most elegant way to abort user input after an empty string is entered?</strong></p>
  
  <p>The approach I tried wont break the input no matter what I enter.</p>
  
  <pre><code>    def populate_list():
      list=[]
      while True:
          try:
              list.append(input("Enter values: "))
          except EOFError:
              break;
      return list
  </code></pre>