Say, I have a 100 text files (100kB each) and I'm interested in searching those files for strings/keywords entered by the user.

One way to do this would be to read them every single time and look for the entered string/keywords and I could implement that but it might be inefficient.

Since I know all the data before hand, are there any other better ways to do this?