## 4. Sum of Perimeters

What is the sum of the perimeters of all mutually incongruent triangles whose perimeter is a natural number, and the lengths of two sides are 7 and 12?
## Solution.

In any triangle, the sum of the lengths of any two sides is greater than the length of the remaining side.

The sides of lengths 7 and 12 are given. The third side cannot be 5 or shorter because $7+5=12$. Similarly, the third side cannot be 19 or longer because $7+12=19$.

The length of the third side is from the set $\{6,7,8,9,10,11,12,13,14,15,16,17,18\}$.

There are a total of 13 such triangles.

In the sum of the perimeters of all these triangles, the sides of lengths 7 and 12 appear 13 times each, and each length from the set $\{6,7,8,9,10,11,12,13,14,15,16,17,18\}$ appears once.

$$
\begin{gathered}
6+7+\cdots+17+18=156 \\
13 \cdot(7+12)=13 \cdot 19=247 \\
247+156=403
\end{gathered}
$$

The sum of the perimeters of all such triangles is 403.