since it's a right triangle
[tex]\bf \textit{using the pythagorean theorem}\\\\
c^2=a^2+b^2\qquad
\begin{cases}
c=hypotenuse\\
a=adjacent\\
b=opposite\\
-------\\
c=8\\
b=a
\end{cases}\implies 8^2=a^2+a^2
\\\\\\
64=2a^2\implies \cfrac{64}{2}=a^2\implies 32=a^2\implies \sqrt{32}=a
\\\\\\
\sqrt{16\cdot 2}=a\implies \sqrt{4^2\cdot 2}=a\implies 4\sqrt{2}=a[/tex]