I am searching for matches in large text file, but I find it way too slow. This is the file structure:
word1 5752
word2 96332
word3 137
I am trying to match text in first column, and I want to extract the value in second column. The columns are separated by \t and there are about 10 million lines. The file is searched many times with different words. What method of searching has the best time efficiency?
EDIT: The file is 129 Mb and will be searched thousands of times at least. EDIT2: File is alphabetically sorted and words can occur multiple times only if they have different capital letters e.g: Word WORD word WOrd will all be different entries.