Hint $ $ For $\,x = \gcd(m,n),\ {\rm lcm}(m,n) = mn/x,\,$ and your equation is $\,(x-m)(x-n) = 0.$ Thus either $\,x = \gcd(m,n) = m,\,$ so $\,m\mid n,\ $ or $\,x = \gcd(m,n) = n,\,$ so $\,n\mid m.$
Hint $\,\ n,m\mid j \!\iff\! nm\mid nj,mj\!$ $\overset{\ \rm\color{darkorange}U}\iff\! nm\mid (nj,mj) \overset{\ \rm \color{#0a0}D_{\phantom |}}= (n,m)j\!$ $\iff\! nm/(n,m)\mid j$
where above we have applied $\,\rm \color{darkorange}U = $ GCD Universal Property and $\,\rm\color{#0a0} D =$ GCD Distributive Law.
Remark $\ $ If we bring to the fore implicit cofactor reflection symmetry we obtain a simpler proof: $ $ it is easy to show $\,d\,\mapsto\, mn/d\,$ bijects common divisors of $\,m,n\,$ with common multiples $\le mn.$ Being order-$\rm\color{#c00}{reversing}$, it maps the $\rm\color{#c00}{Greatest}$ common divisor to the $\rm\color{#c00}{Least}$ common multiple, i.e. $\,{\rm\color{#c00}{G}CD}(m,n)\,\mapsto\, mn/{\rm GCD}(m,n) = {\rm \color{#c00}{L }CM}(m,n).\,$
See here and here more on this involution (reflection) symmetry at the heart of gcd, lcm duality.
Best Answer
HINT
Note that $lcm (m,n) \times \gcd(m,n)=mn$.
If for four real numbers $a+b=c+d$, $ab=cd$, this implies that $a=c, b=d$ or $a=d, b=c$ since they are both two roots to the quadratic equation $x^2-(c+d)x+cd$.