Skip to content

Latest commit

 

History

History
11 lines (6 loc) · 664 Bytes

README.md

File metadata and controls

11 lines (6 loc) · 664 Bytes

Indexing Combinations

How can we compute an index for a given combination of the n integers {1,2,3,...,n} taken k at a time? Also, given such an index, how can we recover the particular combination that has that index?

It turns out that there is a relatively easy-to-compute expression for the index of such a combination and there's a pretty efficient procedure to recover it, given its index.

Originally written on December 5, 2019.

License

I'm sharing this work under the Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license. See the LICENSE file for more information.