sum-outputs ( quot -- n )
Factor handbook » The language » Combinators » Smart combinators

Prev:smart-apply ( quot n -- )
Next:append-outputs ( quot -- seq )


Vocabulary
combinators.smart

Inputs
quota quotation


Outputs
nan integer


Word description
Infers the number of outputs from quot and returns their sum.

Examples
USING: combinators.smart kernel math prettyprint ; 10 [ [ 1 - ] [ 1 + ] bi ] sum-outputs .
20


Definition