3. Let real numbers $x, y$ satisfy
$$
x^{2}+\sqrt{3} y=4, y^{2}+\sqrt{3} x=4, x \neq y \text {. }
$$

Then the value of $\frac{y}{x}+\frac{x}{y}$ is $\qquad$
3. -5 .

From the conditions, we have
$$
\left\{\begin{array}{l}
x^{2}-y^{2}+\sqrt{3} y-\sqrt{3} x=0, \\
x^{2}+y^{2}+\sqrt{3}(x+y)=8 .
\end{array}\right.
$$

From equation (1) and $x \neq y$, we know $x+y=\sqrt{3}$.
Substituting into equation (2) gives $x^{2}+y^{2}=5$.
$$
\begin{array}{l}
\text { Also, } 2 x y=(x+y)^{2}-\left(x^{2}+y^{2}\right)=-2 \\
\Rightarrow x y=-1 . \\
\text { Therefore, } \frac{y}{x}+\frac{x}{y}=\frac{x^{2}+y^{2}}{x y}=-5 .
\end{array}
$$