Handbook
Glossary
bench-combinations ( n -- )
Vocabulary
benchmark
.
combinatorics
Inputs
n
an
object
Outputs
None
Definition
USING:
combinators
kernel
math
math.combinatorics
ranges
sequences
;
IN:
benchmark.combinatorics
:
bench-combinations
( n -- )
[1..b]
dup
clone
[
{
[
all-combinations
drop
]
[
[
drop
]
each-combination
]
[
[
first
2
=
]
find-combination
drop
]
[
0
[
sum
+
]
reduce-combinations
drop
]
}
2cleave
]
with
each
;