From the prime numbers less than 100, five need to be selected such that each of the digits 1, 2, ..., 9 appears exactly once among their digits. In how many ways can this be done?
The number of digits in the five numbers can only equal the number of available digits, 9, if there are 4 two-digit and 1 one-digit numbers among them. The last digit of the two-digit numbers cannot be even and cannot be 5, so it must be one of the following:

$$
1,3,7,9
$$

Thus, the last digit of the four two-digit numbers, in some order, is precisely one of these four numbers, and therefore these numbers cannot appear elsewhere. Among the one-digit prime numbers, only 2 and 5 are possible.

First, let's examine the case where the selected one-digit number is 2. In this case, the first digit of the four two-digit numbers is chosen from the following:

$$
4,5,6,8
$$

And the possible primes are as follows (arranged by their digits):

| 41 | - | 61 | - |
| :---: | :---: | :---: | :---: |
| 43 | 53 | - | 83 |
| 47 | - | 67 | - |
| - | 59 | - | 89 |

We need to determine how many ways we can select four numbers from the above arrangement such that exactly one is chosen from each row and each column.

If we choose 41 from the first row, then we can only choose 67 from the third row, and there are two possibilities for the other two numbers: the pair 53, 89 and the pair 59, 83. This gives us two cases so far. If we choose 61 from the first row, we can only choose 47 from the third row, and we have the same two possibilities for the other two numbers as before. Thus, there are 4 ways to select the 4 two-digit numbers.

The number of possibilities is the same if we choose 5 as the one-digit number, since the possible numbers for the other four can be arranged in the same way as before:

| 41 | - | 61 | - |
| :---: | :---: | :---: | :---: |
| 43 | 23 | - | 83 |
| 47 | - | 67 | - |
| - | 29 | - | 89 |

(only the primes starting with 2 have moved to the second column), and we have the same task as before. In this case, there are also 4 valid selections, and thus the total number of possibilities is 8.

Beck László (Budapest, Berzsenyi D. Gym., I. o. t.)

Csarnai József (Gyula, Erkel F. Gym., II. o. t.)