deep-find ( ... obj quot: ( ... elt -- ... ? ) -- ... elt )
Factor handbook » The language » Collections » Sequence operations » Deep sequence combinators

Prev:deep-filter ( ... obj quot: ( ... elt -- ... ? ) -- ... seq )
Next:deep-any? ( ... obj quot: ( ... elt -- ... ? ) -- ... ? )


Vocabulary
sequences.deep

Inputs
objan object
quota quotation with stack effect ( ... elt -- ... ? )


Outputs
eltan element


Word description
Gets the first sub-node of the object, in preorder, which satisfies the quotation. If nothing satisfies it, it returns f.

See also
find

Definition


: deep-find
( ... obj quot: ( ... elt -- ... ? ) -- ... elt )
(deep-find) drop ; inline