title: Python empty line and text marking
body: <p>I am using following code to pickup 10 random lines, however it's also pickups empty line. I just wanted to exclude empty line while doing selection. and also wants to mark selected line with * as prefix. so next time this code will not pickup any line which start with *. </p>
  
  <pre><code>import random  
  task = 10  
  while ( task &gt;= 0 ):  
      lines = open('master.txt').read().splitlines()
      myline =random.choice(lines)    
      print(myline)  
      task -= 1  
  print ('Done!')
  </code></pre>