chickadee » srfi-127 » lseq-find

lseq-find pred lseqprocedure

Return the first element of lseq that satisfies predicate pred, or #f if no element does. It cannot reliably be applied to lseqs that include #f as an element; use lseq-find-tail instead. The predicate is guaranteed to be evaluated on the elements of lseq in sequence order, and only as often as necessary.

(lseq-find even? '(3 1 4 1 5 9 2 6)) ;=> 4