title: Best way to search multiple files for keywords efficiently in python 3.x?
body: <p>Sorry if this has been asked before, but i didn't seem to find a solution to my problem.</p>
  
  <p>I have around 500 text files, each around 5-6 kB in size. I need to search every file and check if a particular keyword is present in it, and print the details of every file in which the keyword is present.</p>
  
  <p>I can do this using</p>
  
  <pre><code>for files in glob.glob("*"):
        and then search for the keyword inside the file
  </code></pre>
  
  <p>I'm sure this isn't the most efficient way to do this.
  What better way is there?</p>