Find all integers $k, n, m \geq 0$ such that $5^{n}-3^{k}=m^{2}$.
Modulo 4, we see that $k$ is even. Modulo 3, we see that $n$ is even. Let's write $k=2p$ and $n=2q$. Thus, $\left(5^{q}-m\right)\left(5^{q}+m\right)=9^{p}$. Since $5^{q}-m$ and $5^{q}+m$ are coprime, we have $5^{q}+m=9^{v}$ and $5^{q}-m=9^{u}$ with $v>u \geq 0$. Then $2 \cdot 5^{q}=9^{v}+9^{u}$, which forces $u=0$. Thus, $2 \cdot 5^{q}=9^{p}+1$.

If $q=0, p=0$ gives a solution. We assume therefore $q>0$. Modulo 5, we see that $p$ is odd. Let's write $p=2r+1$, so that $2 \cdot 5^{q}=3^{4r+2}+1$. The value $q=1$ gives the solution $p=1$. Suppose therefore $q \geq 2$. Since the order of 3 modulo 25 is 20, we have $8=3^{2}-1\left|3^{20}-1\right| 3^{4r+2}-1$, which is absurd.

The only solutions are therefore $(n, k, m)=(0,0,0)$ and $(n, k, m)=(2,2,4)$.

Remark. From $2 \cdot 5^{q}=9^{p}+1$, we could have invoked Zsigmondy's theorem which implies, when $p \geq 2$, the existence of a prime number $s$ such that $s$ divides $9^{p}+1$ but not $9+1$.