hi all,
I have a bunch of numbers; they are constructed of digits without repetition, and in this numbers a digit is always greater lower value digits. This numbers are categorized according to the its number of digit; in each category all possible numbers are exist.
here a simple example:
assume the numbers constructed of 1, 2, 3, 4, 5 and they are categorized as follow according to number of digits:
1-digit: 1, 2, 3, 4, 5
2-digit: 12, 13, 14, 15, 23, 24, 25, 34, 35, 45
3-digit: 123, 124, 125, 134, 135, 145, 234, 235, 245, 345
4-digit: 1234, 1235, 1245, 1345, 2345
5-digit: 12345
the question is: how I can find a number by knowing the category and the number of its place in row. for example by knowing category number 2 and sequence number 7, I have to obtain: 25
since it becomes cumbersome at higher orders, I need to formulate the procedure. a formula or a algorithm is appreciated.
Thank you
I have a bunch of numbers; they are constructed of digits without repetition, and in this numbers a digit is always greater lower value digits. This numbers are categorized according to the its number of digit; in each category all possible numbers are exist.
here a simple example:
assume the numbers constructed of 1, 2, 3, 4, 5 and they are categorized as follow according to number of digits:
1-digit: 1, 2, 3, 4, 5
2-digit: 12, 13, 14, 15, 23, 24, 25, 34, 35, 45
3-digit: 123, 124, 125, 134, 135, 145, 234, 235, 245, 345
4-digit: 1234, 1235, 1245, 1345, 2345
5-digit: 12345
the question is: how I can find a number by knowing the category and the number of its place in row. for example by knowing category number 2 and sequence number 7, I have to obtain: 25
since it becomes cumbersome at higher orders, I need to formulate the procedure. a formula or a algorithm is appreciated.
Thank you