9-8-1. In Midcity, houses stand along one side of a street, each house can have $1,2,3, \ldots, 9$ floors. According to an ancient law of Midcity, if two houses on one side of the street have the same number of floors, then no matter how far apart they are from each other, there must be a house with more floors between them. What is the maximum possible number of houses on one side of the street in Midcity?
Answer: 511.

Solution Variant 1. Estimation. Let $a_{k}$ be the maximum number of houses if all of them have no more than $k$ floors. Clearly, $a_{1}=1$. Let's find $a_{k}$. Consider the tallest house with $k$ floors, which is only one by the condition. Both to the left and to the right of it stand houses with $1,2,3, \ldots, k-1$ floors, and for the houses on each side, the ancient law of Mezhdugrad for $(k-1)$-floor houses is satisfied. Therefore, the total number of houses is no more than $a_{k-1}+1+a_{k-1}$ (houses to the left, the tallest house with $k$ floors, houses to the right). Thus, $a_{k} \leqslant 1+2 a_{k-1}$. Let's calculate using this formula: $a_{2} \leqslant 1+2 \cdot 1=3 ; a_{3} \leqslant 1+2 \cdot 3=7 ; a_{4} \leqslant 1+2 \cdot 7=15, \ldots$ One can notice the pattern $a_{m} \leqslant 2^{m}-1$, from which $a_{9} \leqslant 2^{9}-1=511$.

Example. Along the street, houses can stand as follows:

$$
12131214121312151213121412131216 \ldots
$$

a total of $2^{2}-1=511$ houses.

This example is constructed from the estimation: place the 9-floor house in the center, and to the left and right of it, write examples for no more than 8-floor houses. These examples for no more than 8-floor houses are constructed similarly: place the 8-floor house in the center, and to the left and right of it, write examples for no more than 7-floor houses, and so on. In the end, the example above is obtained.