title: Most efficient way to traverse file structure Python
body: <p>Is using os.walk in the way below the least time consuming way to recursively search through a folder and return all the files that end with .tnt?</p>
  
  <pre><code>for root, dirs, files in os.walk('C:\\data'):
      print "Now in root %s" %root
      for f in files:
          if f.endswith('.tnt'):
  </code></pre>