Hi, could anyone please tell me what I'm doing wrong? I'm supposed to read from the input.txt, which contains several lines of text, for example:
Considering what people have said already: is this something that you're having to do as part of a student assignment ("homework" :-) using classic Pascal, or is this something that you're free to do any way you want?
The point's already been made that you can't redefine input and output, classical Pascal texts will often show that the first line of a program reads
and in the general case those identifiers should be treated as reserved.
You are unlikely to be able to seek inside a text file, unless you start handling all the I/O yourself. At best, I'd expect the availability of that to be implementation-defined.
That means that you're probably going to need to put the lines you read into an array or list. However the detail of that depends on what facilities you're prepared or allowed to use.
MarkMLl