Fastest Method of Searching
Posted on 1999-01-29
I have a text file about 3 Meg in size. I have to search for a string of about 7 characters in length at the beginning of each line. Each line can be well over 300 characters. Currently I am opening the file and reading the whole line with fgets and comparing the first 7 characters. What would be the best method for this as I need to increase the speed.