How many 6-digit sequences are ascending, like 023689, 033588, or 222222?
A number may begin with 0 and can be repeated, but must be increasing.
I am not entirely certain how to approach this problem.
combinatorics
How many 6-digit sequences are ascending, like 023689, 033588, or 222222?
A number may begin with 0 and can be repeated, but must be increasing.
I am not entirely certain how to approach this problem.
Best Answer
Notice that since the digits in the string are ascending, such a number is completely determined by how many times each digit appears in the string. For example, if the six digits $0, 2, 3, 6, 8, 9$ each appear once, we obtain the string $023689$. If the digits $0$ and $5$ each appear once and the digits $3$ and $8$ each appear twice in the six-digit string, then we obtain the string $033588$.
Let $x_i$, $0 \leq i \leq 9$, be the number of times that the digit $i$ appears in the six-digit string. Then $$x_0 + x_1 + x_2 + x_3 + x_4 + x_5 + x_6 + x_7 + x_8 + x_9 = 6$$ is an equation in the nonnegative integers. The number of ascending strings of length six is the number of solutions of this equation in the nonnegative integers.