Open
Description
integer_partitions(n)
should be deprecated in favour of partitions(n::Integer)
.
Additionally, partitions
is not documented in the readme.
These functions currently do not behave the same:
In the 0 case, both are broken, the partitions
case discussed in #79 :
julia> integer_partitions(0)
0-element Array{Array{Int64,1},1}
julia> partitions(0)|>collect
1-element Array{Array{Int64,1},1}:
#undef
but should return [[]]
For n>0
the results of integer_partitions
is sorted opposite to partitions
:
julia> collect(partitions(3))
3-element Array{Array{Int64,1},1}:
[3]
[2, 1]
[1, 1, 1]
julia> integer_partitions(3)
3-element Array{Array{Int64,1},1}:
[1, 1, 1]
[2, 1]
[3]
Metadata
Metadata
Assignees
Labels
No labels