;;; Example for reading and displaying the contents of a file ;; Creates a file handle for reading junk.txt (define fhr (open-file "junk.txt" "r") ) ;;; Reads and displays each object of junk.txt (define (readfile fh) (let ((str (read fh))) (if (eof-object? str) (display "\n") (begin (map display (list str "\n")) (readfile fh) ) ) ) )