For this equation $x*y = 5x + 5y$ find all possible pairs.
The way I did it was: $x=5y/(y-5)$
And for this I wrote a program to brute force a couple of solutions. If it helps, some possibilities are: [4,-20], [6, 30], [10, 10]
So my question is: What is a mathematically correct way to solve this problem?
$$5x+5y-xy=0$$ $$5x+5y-xy-25=-25$$ $$x(5-y)-5(5-y)=-25$$ $$(x-5)(y-5)=25$$ 1) $x-5=1; y-5=25; \Rightarrow x=6; y=30$;
2) $x-5=-1; y-5=-25; \Rightarrow x=4; y=-20$;
3) $x-5=5; y-5=5; \Rightarrow x=10; y=10$
4) $x-5=-5; y-5=-5; \Rightarrow x=0; y=0$
5) $x-5=25; y-5=1; \Rightarrow x=30; y=6$
6) $x-5=-25; y-5=-1; \Rightarrow x=-20; y=4$