Skip to main content

some

functionv1.0

clojure.core/some

Available in:BBCLJCLJS
(some [pred coll])
Returns the first logical true value of (pred x) for any x in coll, else nil. One common idiom is to use a set as pred, for example this will return :fred if :fred is in the sequence, otherwise nil: (some #{:fred} coll)

No examples yet. Be the first to add one!