DEPRECATED. Prefer clojure.core version.
Returns a lazy sequence of lists like clojure.core/partition, but may
include lists with fewer than n items at the end.
(defn partition-all
"DEPRECATED. Prefer clojure.core version.
Returns a lazy sequence of lists like clojure.core/partition, but may
include lists with fewer than n items at the end."
{:deprecated "1.2"}
([n coll]
(partition-all n n coll))
([n step coll]
(lazy-seq
(when-let [s (seq coll)]
(cons (take n s) (partition-all n step (drop step s)))))))
Comments top
No comments for partition-all. Log in to add a comment.