The probability that a randomly chosen 5-digit number is made from exactly two digits is:
First we note that a 5-digit number runs from 10000 to 99999, so its left-most digit can be 1,2,…,9. Hence the total number of 5-digit numbers is
Our task is to count how many of these 90000 numbers use exactly two distinct digits. Both chosen digits must appear at least once inside the 5 positions.
We begin by choosing the two digits. Choosing two different digits out of the ten possible digits 0-9 is done by the combination formula
so
unordered pairs of digits are possible. Now we split these 45 pairs into two convenient classes, depending on whether 0 is one of the chosen digits.
Class 1: Neither digit is 0. There are 9 non-zero digits, so the number of such unordered pairs is
Fix any one of these 36 pairs, say {a,b} with a≠b and both a,b∈{1,…,9}. We form 5-length strings from {a,b} such that both a and b occur and the first digit is non-zero (already guaranteed here). Without any restriction each of the 5 positions could be chosen in 2 ways, giving
strings. From these 32 we must discard the two monochromatic strings aaaaa and bbbbb in which both digits do not appear. Hence
valid numbers arise from any fixed pair {a,b}. Multiplying by the 36 choices of the pair gives
valid 5-digit numbers in Class 1.
Class 2: Exactly one digit is 0. Here the pair is {0,b} with b∈{1,…,9}. There are
such pairs. For each pair the first digit of the number cannot be 0 (otherwise we would not have a 5-digit number), so the first digit is forced to be b. The remaining four positions can be filled with either 0 or b, but 0 must appear at least once among them so that both digits occur. For the last four places we have
total strings, of which exactly one, namely bbbb, contains no 0. Therefore the admissible strings for the last four places are
\
Thus each pair {0,b} contributes 15 numbers, and altogether Class 2 supplies
valid 5-digit numbers.
Adding the two classes together, the number of favourable 5-digit numbers is
The required probability is therefore
We now simplify this fraction. Both numerator and denominator are divisible by 45, because
So we get
To match the form given in the options we multiply numerator and denominator by 5:
This expression appears as Option A.
Hence, the correct answer is Option A.
Tagged Probability using permutations and combinations. Machine-assigned, so read it as a strong shortlist rather than a verdict.