I've been making this program to identefy a string in a file, and to write down the raws were it appears...
the problem was that when I wrote just
it would read the last raw (string) twice... say I had 6 lines in the text file.. and the string would be in the 6th one..
I would get - line 6 AND line 7 as an output....
it had something to do with EOF cause after changing it to that:
it read it fine....
can anyone explain why???
sorry about the long thread...