Read a file one line at a time,
as opposed to reading the entire file at once.



Related tasks

 Read a file character by character
 Input loop.


$ include "seed7_05.s7i";
 
const proc: main is func
  local
    var file: aFile is STD_NULL;
    var string: line is "";
  begin
    aFile := open("input.txt", "r");
    while hasNext(aFile) do
      readln(aFile, line);
      writeln("LINE: " <& line);
    end while;
  end func;