Example 1. The numbers 1447, 1005, and 1231 have something in common. That is, each number is a four-digit number starting with $\mathrm{i}$, and in each four-digit number, exactly two digits are the same. How many such four-digit numbers are there? (1st AIME)
Solve for the four-digit numbers that must contain one 1 or two 1s.
(i) The case with two $\hat{\mathrm{i}} 1$s
Choose two numbers from the remaining 9 digits (excluding 1), which has $C_{9}^{2}$ ways. Then, form any permutation of a three-digit number with these two numbers and one 1, which has $P_{3}^{3}$ ways. Thus, the four-digit numbers starting with 1 are $N_{1}=C_{9}^{2} \cdot P_{3}^{2}$ (numbers).
(ii) The case with only one 1
Choose two numbers from the remaining 9 digits $\left(C_{9}^{2}\right)$, and one of these numbers is repeated $\left(C_{2}^{1}\right)$. The three digits can form a three-digit number in $\frac{P_{3}^{3}}{2}$ ways. Thus, the four-digit numbers starting with 1 are $N_{2}=\frac{C_{9}^{2} \cdot C_{2}^{1} \cdot P_{3}^{3}}{2}$ (numbers).
Therefore, the total number of four-digit numbers that meet the criteria is
$$
N=N_{1}+N_{2}=432 \text { (numbers). }
$$