They are lazy -- change "for" to "doseq"
From: clojure@googlegroups.com [clojure@googlegroups.com] on behalf of Kevin
Kleinfelter [kleinfelter.gro...@gmail.com]
Sent: 17 May 2017 19:14
To: Clojure
Subject: Let and For Doesn't Execute - Where Is My Mis
On 17 May 2017, at 19:14, Kevin Kleinfelter
wrote:
> I'm stumped by the behavior of the following code fragment. Can someone help
> me understand what's happening?
>
> This code:
> (println "Holding:" (:class holding))
> (let [t (:class holding)]
> (for [x t] (println "here" x))
>
Kevin Kleinfelter writes:
> I'm stumped by the behavior of the following code fragment. Can someone
> help me understand what's happening?
>
> *This code*:
> (println "Holding:" (:class holding))
> (let [t (:class holding)]
> (for [x t] (println "here" x))
> (for [x t] (println