Handbook
Glossary
2each ( ... seq1 seq2 quot: ( ... elt1 elt2 -- ... ) -- ... )
Factor handbook
»
The language
»
Collections
»
Sequence operations
»
Sequence combinators
»
Pair-wise sequence combinators
Next:
2reduce ( ... seq1 seq2 identity quot: ( ... prev elt1 elt2 -- ... next ) -- ... result )
Vocabulary
sequences
Inputs
seq1
a
sequence
seq2
a
sequence
quot
a
quotation
with stack effect
( ... elt1 elt2 -- ... )
Outputs
None
Word description
Applies the quotation to pairs of elements from
seq1
and
seq2
.
Definition
USING:
math
sequences.private
;
IN:
sequences
:
2each
( ... seq1 seq2 quot: ( ... elt1 elt2 -- ... ) -- ... )
2length-operator
each-integer
;
inline