I was mathematically shown 1 = 2 by a function that states the following
$$x^2-x^2 = x^2-x^2 $$ $$x(x-x)=(x-x)(x+x)$$
dividing by $(x-x)$ we get...
$$x=x+x$$ $$ x=2x$$ $$1=2$$
I can see that mathematically he was right, but for sure that I was missing something as it doesn't make mathematical sense
So this does not go unanswered...as others have mentioned, the obvious error is that you are dividing by $0$ by when you divide by $x-x$. Thus, whatever conclusion you reach is most certainly flawed.
The irksome thing in this case is that the flaw is hardly subtle. I would recommend you see this post for a much more interesting attempt to fool readers into thinking $0=1$.