Skip to content

clojure.core/interleave

View this page on ClojureDocs

Type: function Added: Clojure 1.0 Examples: 7 Runnable: 7
([] [c1] [c1 c2] [c1 c2 & colls])

Returns a lazy seq of the first item in each coll, then the second etc.

Examples

by cdorrat on
by kotarak on
by kotarak on
by octopusgrabbus on
by octopusgrabbus on
by ttkk1024 on
by bfontaine on

Note by holtzermann17

Behaviour of

(interleave [4 5 6])
apparently depends on which Clojure version you're using. In 1.10.0 the result is:

[4 5 6]

See also


Content from the matching ClojureDocs page, with authors credited on each contribution.