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.


; Commented line below should be uncommented to use read-line with Guile
;(use-modules (ice-9 rdelim))
 
(define file (open-input-file "input.txt"))
(do ((line (read-line file) (read-line file))) ((eof-object? line))
        (display line)
        (newline))