I wonder what the difference is. Maybe in unicode one is slightly longer than the other, but at the end of the day, aren't they both just a horizontal line?
5 − 2 = 3
5 - 2 = 3
The first one is correct. It contains the Unicode character 'MINUS SIGN' (U+2212). The second contains the Unicode character 'HYPHEN-MINUS' (U+002D) which is not suitable for representing the minus sign in mathematical typesetting.
Also, see https://i.imgur.com/ngFI3JB.png for a few examples typeset with MathJax. The first example has a proper minus sign (correct) whereas the second one contains a hyphen (incorrect). By the way, in plain HTML, the character entity reference "−" displays the minus sign, although I just use MathJax when proper mathematics typesetting is required in HTML pages.
A properly rendered minus is identical to the horizontal stroke of a plus (whereas hyphen is frequently shorter and/or incorrectly vertically aligned).