A safe has a 4-digit lock code that does not include zero as a digit and no digit is repeated. What is the probability that the lock code consists of all even digits?



To find the total number of outcomes for this event, find the permutation of
things taken 4 at a time.

The total number of outcomes is
.

The total number of favorable outcomes is a permutation of
things taken 4 at a time.

The probability that the lock code consists of all even digits is
out of 3,024.

1 answer

To determine the probability that a 4-digit lock code consists of all even digits, we first need to identify the constraints provided in the problem.

Step 1: Total Outcomes

Since the lock code cannot include the digit zero and no digit can be repeated, the valid digits we can use are {1, 2, 3, 4, 5, 6, 7, 8, 9}. This gives us a total of 9 digits to choose from.

The number of different 4-digit lock codes can be calculated by finding the number of permutations of 9 digits taken 4 at a time. This can be calculated using the formula for permutations:

\[ P(n, r) = \frac{n!}{(n-r)!} \]

where \( n \) is the total number of options and \( r \) is the number of slots to fill. In this case:

\[ P(9, 4) = \frac{9!}{(9-4)!} = \frac{9!}{5!} = 9 \times 8 \times 7 \times 6 = 3024 \]

Step 2: Favorable Outcomes

Next, we determine the number of favorable outcomes where all four digits are even. The even digits from the possible set {1, 2, 3, 4, 5, 6, 7, 8, 9} are {2, 4, 6, 8}. This gives us 4 even digits to choose from.

We want the number of ways to create a 4-digit code using these 4 digits, where all digits must be different. The number of ways to arrange these 4 digits is given by the number of permutations of 4 digits taken 4 at a time:

\[ P(4, 4) = \frac{4!}{(4-4)!} = 4! = 24 \]

Step 3: Probability Calculation

Now, we can calculate the probability that a 4-digit lock code consists of all even digits by dividing the number of favorable outcomes by the total outcomes:

\[ \text{Probability} = \frac{\text{Number of favorable outcomes}}{\text{Total outcomes}} = \frac{24}{3024} \]

To simplify:

\[ \frac{24}{3024} = \frac{1}{126} \]

Conclusion

Therefore, the probability that the lock code consists of all even digits is

\[ \frac{1}{126} \text{ out of } 3024. \]