[Python-ideas] Implement `itertools.permutations.__getitem__` and `itertools.permutations.index`

Tal Einat taleinat at gmail.com
Wed May 7 19:40:22 CEST 2014


On Wed, May 7, 2014 at 8:21 PM, Ram Rachum <ram.rachum at gmail.com> wrote:
> Hi Tal,
>
> I'm using it for a project of my own (optimizing keyboard layout) but I
> can't make the case that it's useful for the stdlib. I'd understand if it
> would be omitted for not being enough of a common need.

At the least, this (a function for getting a specific permutation by
lexicographical-order index) could make a nice cookbook recipe.

- Tal


More information about the Python-ideas mailing list