Hi
When I read this post in the morning I thought about how I would
implement this function, and the result was:
(defn take-by
[f coll]
(when-let [[x & xs] (seq coll)]
(let [n (f x)]
(lazy-seq (cons x (take-while #(= n (f %)) xs))
I didn't post it, because I really am a beginne
Thank you for your time and kind answers. I really enjoy reading this
group and the whole clojure community. Enough flattery ;)
A question remains though (for now).
Would I use
(lazy-seq
(some
(stuff ...)))
instead of
(some
(stuff
(lazy-seq ...)))
because some stuff would only be
Hi
Since you're working with XP, I can recommend Lisp Cabinet from
http://lispcabinet.sourceforge.net/ . It has a windows istaller and
works out of the box. An additional advantage may be the availability
of various lisp implementations parallel to clojure. Didn't get that
configured in several at