Solving for $y$, where am I going wrong? If I solve for $y$ one way I get one answer, but if I solve a different way (switching the order of the initial equality) I get a completely different answer which apparently is wrong. Just wondering where I am going wrong the second way.
First Way (Correct):
$$5y+2 = xy-3x$$
$$5y-xy+2 = -3x$$
$$5y-xy = -3x-2$$
$$y(5-x) = -3x-2$$
$$y = \frac{-3x-2}{5-x}$$
Second Way (Incorrect):
$$xy-3x = 5y+2$$
$$xy-3x-5y = 2$$
$$xy-5y = 2+3x$$
$$y(x-5) = 2+3x$$
$$y = \frac{2+3x}{x-5}$$

$$y = \frac{-3x-2}{5-x}=\frac{-(3x+2)}{-(x-5)}=\frac{2+3x}{x-5}$$
Both are correct as they are equivalent given $x \neq 5$
