title: re.match returns memory error in python
body: <pre><code>def name():
  
      with open('newfile.txt') as f:
          lineno = f.readlines()
  
      for line in lineno:
          h = re.compile('(#DESIGNATION\ \:[\n\t]*)((.)*[\n\t]*)*?\#')
          print h.match(line)
  
  name()
  </code></pre>
  
  <p>newfile.txt contains about 100 lines. When run this program give error <code>MemoryError</code>. While removing ? from <code>'(#DESIGNATION\ \:[\n\t]*)((.)*[\n\t]*)*?\#</code>', gives no error. Why is this happening and what are feasible solutions.
  Thanks.</p>