315. The numbers $2 \overline{a c}+1$ and $3 \overline{a c}+1$ are perfect squares. Find $\overline{a c}$.
315. First method. By setting $\overline{a c}=x$, we obtain the system $\left\{\begin{array}{l}2 x+1=y^{2} \\ 3 x+1=z^{2}\end{array}\right.$, i.e., $\frac{y^{2}-1}{2}$ and $\frac{z^{2}-1}{3}$ represent equal integers.

It is easy to find $x=2 t^{2}+2 t$ and $x=3 t_{1}^{2} \pm 2 t_{1}$. According to the problem's condition, we get $\left\{\begin{array}{l}2 t^{2}+2 t>9 \\ 2 t^{2}+2 t<100\end{array}\right.$ and $\left\{\begin{array}{l}3 t_{1}^{2} \pm 2 t_{1} \geq 9 \\ 3 t_{1}^{2} \pm 2 t_{1}<100\end{array}\right.$, from which we find $x=12,24,40,60,84 ; x=21,40,65$, $96,16,33,56,85$.

From this, we conclude that $\overline{a c}=40$.

Second method. Excluding $x$ from the system $\left\{\begin{array}{l}2 x+1=y^{2} \\ 3 x+1=z^{2}\end{array}\right.$, we find the equation $3 y^{2}-2 z^{2}=1$.

Solving this equation using the method indicated in № 266, we get $y=9, z=11$, hence $x=40$.