reduce's docstring says, "If coll has only 1 item, it is returned and f is
not called."
--
--
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 -
Is this happening on lines: for (reduce conj ["A"])
[f val coll] gets called eventually from [f coll] and since s does not
exist it ends with val straight.
(def reduce
(fn r
([f coll]
(let [s (seq coll)]
(if s
(r f (first s) (next s))