Say I have three elements: A, B, C. I can list all the permutations by going alphabetical in the first element, then the second, then the third, and so on, like so:
ABC
ACB
BAC
BCA
CAB
CBA
What I'm wondering, is given a number N, how do I decompose this into knowing what permutation it...