CodeMonkey2000 @ Sun Jan 20, 2008 9:22 pm wrote:
No, it still goes past the eof. Why doesn't this work?
Assuming that all the file reading code is there (none in the "whatever") and that your input is of the right form, I am not quite sure why it doesn't work (may be missing something obvious though). If you did not type the input file yourself, make sure you try with something that you saved on the same machine with a reasonable text editor. If you are using DOS/Windows editors, your file may have a DOS end-of-file character that is confusing your program.