How many numbers without repetition starting with zeros we can produce from the numbers like $1001, 10020003$ and $2000005$? How do I evaluate this? Is there an easy way? I know that the number we can produce with them without repetition must be $\dfrac{n!}{a!b!c!...k!}$, being n the amount of digits present in each number and $a, b, c, ..., k$, how many each distinct number appears. For example: for the number 1001, we have $n = 4, a = 2$ (because $1$ appears twice) and $b = 2$ (because $0$ appears twice) and:
$$P = \dfrac{4!}{2!2!} = \frac{12}{2} = 6$$
Thus, $6$ distinct numbers with $4$ digits can be produced from $1001$, but how many start with $1$ or $2$ zeros in this case?
Let $[a_n]_{n\in\{0,1,2,3,4,5,6,7,8,9\}}$ be the sequence of counts of digits in the number. For instance if the number is $1001$, the sequence is $[2,2,0,0,0,0,0,0,0,0]$ because $a_0=a_1=2,$ and there are no other digits.
Then the count ways to select places for the digits in non-leading-zero arrangements is: $$\dfrac{(a_0{+}a_1{+}\ldots{+}a_9)!}{a_0!~a_1!~\cdots~a_9!}- \dfrac{(a_0{+}a_1{+}\ldots{+}a_9-1)!}{(a_0-1)!~a_1!~\cdots~a_9!}\mathbf 1_{a_0>0}$$
That is: The count of all possible arrangements minus the count of all arrangements where zero leads (when there is at least one zero).
So when the number is $1001$ this is: $\frac{4!}{2!2!}-\frac{3!}{1!2!}$