3. Given that in the right triangle $\triangle A B C$, one side length is 5, and the other two side lengths are exactly the two roots of the equation $x^{2}-7 x+4 k-4=0$. Then the value of $k$ is $\qquad$ .
3.4 or $\frac{160}{49}$.

Let the other two sides be $m, n (m \geqslant n)$.
By the relationship between roots and coefficients, we have
$$
\left\{\begin{array}{l}
m+n=7, \\
m n=4 k-4 .
\end{array}\right.
$$

When $m>5$, we have
$$
n^{2}+5^{2}=m^{2} \Rightarrow(m+n)(m-n)=25 \text {. }
$$

Then $m-n=\frac{25}{7}$.
Solving equations (1) and (3) simultaneously, we get $m=\frac{37}{7}, n=\frac{12}{7}$.
Substituting into equation (2) gives $k=\frac{160}{49}$.
When $m<5$, we have $m^{2}+n^{2}=5^{2}$, i.e., $(m+n)^{2}-2 m n=25$.
Substituting in, we get $7^{2}-2(4 k-4)=25 \Rightarrow k=4$.
In this case, $m=4, n=3$.
In summary, the value of $k$ is 4 or $\frac{160}{49}$.