In a right triangle, the perimeter is equal to 30. How many integer values can the hypotenuse take? (Answer:2)
I did:
$a+b+h = 30\rightarrow a+b = h-30\\
a^2+b^2 = h^2 \rightarrow h = \sqrt{a^2+b^2}\\
a-b<h<a+b \rightarrow a-b < h < \sqrt{a^2+b^2}-30...\\
\text{I didn't find other relationships...}
 $

The sides of a general triangle are the roots of the cubic equation
\begin{align} 
 x^3-2\rho x^2+(\rho^2+r^2+4rR)x-4\rho r R&=0
 \tag{1}\label{1}
\end{align}
where $\rho,r$ and $R$ are the semiperimeter, the inradius and
the circumradius, respectively, of the corresponding triangle.
We are given that $\rho=\tfrac{30}2=15$ and also,
since $c$ is the hypotenuse, $c=2R$. So, \eqref{1} transforms to
\begin{align} 
c(r+c-15)^2&=0
\tag{2}\label{2}
\\
\text{or just}\quad
c&=15-r
\tag{3}\label{3}
,
\end{align}
so the integer values of $c$ are defined by integer values of $r$.
Also, since for any valid non-degenerate non-equilateral triangle
\begin{align}
r&\in(0,\tfrac R2)
\tag{4}\label{4}
,
\end{align}
we must have
\begin{align} 
15-r&> 4r
\tag{5}\label{5}
\\
\text{or }\quad
r&<3
\tag{6}\label{6}
\end{align}
and we have only two options left:
\begin{align}
r_1&=1
,\quad
c_1=14
\tag{7}\label{7}
\\
\text{and }\quad
r_2&=2
,\quad
c_2=13
\tag{8}\label{8}
.
\end{align}
So, the answer is indeed, $2$, we don't even have to find the other side lengths.
However, it's trivial, since by factoring \eqref{1} they can be found
as a roots of quadratic
\begin{align}
x^2-(30-c) x+450-30c&=0
\tag{9}\label{9}
,
\end{align}
hence for $c_1=14$ two other sides are
$8\pm\sqrt{34}$
and for
$c_2=13$ two other sides are
$5$ and $12$.

Edit
Using geometric approach, when $c=|AB|$ is fixed, the third point $C$
must be located at the intersection of the circle centered at
$O$, the midpoint of $AB$, and the ellipse focused at $A,B$
for which $|AC|+|BC|=30-|AB|$. These are only two possible solutions, that corresponds to $c_1$ and $c_2$.
\begin{align}
\begin{array}{ccc} 
R            & \text{major semi-axis} & \text{minor semi-axis} 
\\ \hline
7 & 8 & \sqrt{15}
\\ 
6.5 & 8.5 & \sqrt{30}
\\ \hline
\end{array}
\end{align}


