Thanks! but not entirely convinced. At my REPL: user> (repeatedly 10 #(do (print "f") [(rand-int 10)])) (ff[0] f[8] f[5] f[7] f[1] f[6] f[7] f[3] f[3] [0])
user> (take 5 (apply concat (repeatedly 10 #(do (print "f") [(rand-int 10)])))) ffff(7 1 f6 f5 8) Only six "f"s... so doesn't that mean the (repeatedly... ) is being evaluated lazily? Alistair On Jul 27, 12:43 pm, Mark Nutter <manutte...@gmail.com> wrote: > On Mon, Jul 26, 2010 at 9:53 AM, atucker <agjf.tuc...@googlemail.com> wrote: > > Here is my function: > > (defn json-seq [] > > (apply concat > > (map #(do (print "f") (str/split (slurp %) #"\nStatusJSONImpl")) > > out-files))) > > Try removing the "apply concat" at the front, I'm pretty sure that's > making your sequence non-lazy. > > Mark -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en