114k views
5 votes
7. Each student received a 4 digit code to use the library computers, with no digit repeated. Moesha received the code 7654. What was the probability that she would received a code of consecutive numbers?​

User Jmikola
by
8.6k points

1 Answer

3 votes

Answer:

The probability that Moesha received a code of consecutive numbers is 0.098, or approximately 9.8%.

Explanation:

There are 4 digits in the code, and each digit must be different.

To count the number of codes with consecutive numbers, we can count the number of possible codes that have 3 consecutive digits and multiply by 3 (since there are 3 ways to arrange 3 consecutive digits in a 4-digit code) and then add the number of codes that have 2 consecutive digits and multiply by 2 (since there are 2 ways to arrange 2 consecutive digits in a 4-digit code).

Codes with 3 consecutive digits: There are 7 possible sets of 3 consecutive digits (1234, 2345, 3456, 4567, 5678, 6789, and 7890), and for each set there are 6 possible arrangements (e.g. 1234, 2345, 3456, 4567, 5678, and 6789). So there are 7 x 6 = 42 codes with 3 consecutive digits.

Codes with 2 consecutive digits: There are 9 possible pairs of consecutive digits (01, 12, 23, 34, 45, 56, 67, 78, and 89), and for each pair there are 7 possible non-consecutive digits (e.g. if the pair is 01, the non-consecutive digits are 2, 3, 4, 5, 6, 7, and 8). So there are 9 x 7 x 2 = 126 codes with 2 consecutive digits.

The total number of possible codes is 9 x 8 x 7 x 6 (since there are 9 choices for the first digit, 8 for the second, 7 for the third, and 6 for the fourth). So the probability that Moesha received a code with consecutive numbers is:

(42 + 126) / (9 x 8 x 7 x 6) = 0.098

User Saalon
by
8.0k points