Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/combinations.jl
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ function combinations(a, t::Integer)
# generate 0 combinations for negative argument
t = length(a) + 1
end
reorder(c) = [a[ci] for ci in c]
(reorder(c) for c in Combinations(length(a), t))
# generate all reorderings of 'a' based on combinations of indexes
(a[c] for c in Combinations(length(a), t))
end


Expand Down