B1. We consider numbers of two or more digits where none of the digits is 0. We call such a number thirteenish if every two adjacent digits form a multiple of 13. For example, 139 is thirteenish because $13=1 \times 13$ and $39=3 \times 13$.

How many thirteenish numbers of five digits are there?
B1. 6 The multiples of 13 that consist of two non-zero digits are 13, 26, 39, 52, 65, 78, and 91. In a thirteenish number, a 1 can only be followed by a 3, and a 2 can only be followed by a 6. The digit 4 cannot be followed by any digit. In the figure, each digit is marked with the digit that can follow it.
![](https://cdn.mathpix.com/cropped/2024_04_17_cb88577c1f7dc72a0c75g-1.jpg?height=156&width=704&top_left_y=938&top_left_x=687)

For the first digit of a thirteenish number with more than two digits, we can only choose from $1, 3, 9, 2, 6$, and 5. Subsequently, all following digits are fixed.

We now see that 13913, 26526, 39139, 52652, 65265, and 91391 are the thirteenish numbers of five digits. Thus, there are 6 of them.