I downloaded the Wikipedia article titles file which contains the name of every Wikipedia article. I need to search for all the article titles that may be a possible match.  For example, I might have the word "hockey", but the Wikipedia article for hockey that I would want is "Ice_hockey".  It should be a case-insensitive search too.
I'm using Python, and is there a more efficient way than to just do a line by line search?  I'll be performing this search like 500 or a 1000 times per minute ideally.  If line by line is my only option, are there some optimizations I can do within this?
I think there are several million lines in the file.
Any ideas?
Thanks.
I'd suggest you put your data into an sqlite database, and use the SQL 'like' operator for your searches.
most efficient way to find partial string matches in large file of strings (python)