Combinatorial number system encoder/decoder https://en.wikipedia.org/wiki/Combinatorial_number_system
Cardinality (maximum value plus one) of the packed representation
See Implementation
Combinatorial number system encoder/decoder https://en.wikipedia.org/wiki/Combinatorial_number_system