13. If the eight digits $1,2,3,4,5,6,7,8$ are randomly permuted, what is the probability that the resulting eight-digit number is divisible by 8 ?
若把 $1 、 2 、 3 、 4 、 5 、 6 、 7 、 8$ 這八個數字任意排列, 所得八位數可被 8 整除的概率是多少?
13. $\frac{1}{8}$
13. It suffices to consider the last three digits. There are $8 \times 7 \times 6=336$ possibilities, and we need to count how many of these are divisible by 8 . To be divisible by 8 , the unit digit must be 2,4 , 6 or 8 . We consider these cases one by one.
- If the unit digit is 2 , the tens digit must be $1,3,5$ or 7 in order for the number to be divisible by 4 . If the tens digit is 1 or 5 , there are 3 choices of hundreds digit (e.g. if the tens digit is 1 , then the hundreds digit must be 3,5 or 7 as 312,512 and 712 are divisible by 8 ); if the tens digit is 3 or 7 , there are also 3 choices (namely, 4, 6, 8). Hence there are $3 \times 4=12$ possibilities in this case.
- If the unit digit is 4 , the tens digit must be 2,6 or 8 , leading to 8 possibilities, namely, 624 , 824, 264, 864, 184, 384, 584, 784 .
- The case where the unit digit is 6 is essentially the same as the first case; 12 possibilities.
- The case where the unit digit is 8 leads to 10 possibilities (it is slightly different from the second case), namely, 128, 328, 528, 728, 168, 368, 568, 768, 248 and 648.
It follows that the answer is $\frac{12+8+12+10}{336}=\frac{1}{8}$.