Problem 3 · The crossed triangles
The crossing height doesn't depend on the base: $h = \tfrac{ab}{a+b}$.
Integer answer, at most 4 digitsThe figure shows two overlapping right triangles that share a leg. How long is the segment marked with a question mark?

Copa Cangur · SCM
Medium
Closed answer
Reasoned solution
Key idea: this is the classic crossed-ladders setup: the crossing height comes from two similarities and doesn't depend on the width.
Put the common base of length $L$, the $20$ m side on the left and the $30$ m side on the right. The two hypotenuses are the lines $y = \tfrac{30}{L}x$ and $y = \tfrac{20}{L}(L - x)$. At the crossing point:
$$\frac{30x}{L} = \frac{20(L-x)}{L} \;\Longrightarrow\; 30x = 20L - 20x \;\Longrightarrow\; x = \frac{2L}{5},$$
$$h = \frac{30}{L} \cdot \frac{2L}{5} = 12\ \text{m}, \qquad \text{equivalently } \frac{1}{h} = \frac{1}{20} + \frac{1}{30}.$$
Note that $L$ cancels out: the height would be $12$ for any width of the figure.
Answer: 12