Posted By

ef on 12/08/11


Tagged

file print read


Versions (?)

Printing files in Clojure


 / Published in: Clojure
 

Preferred way of printing files in Clojure.

  1. (defn print-file [filename]
  2. (with-open [rdr (clojure.java.io/reader filename)]
  3. (println (line-seq rdr))))

Report this snippet  

You need to login to post a comment.