Open sjorsvanheuveln opened 6 years ago
Any workaround for this issue?
What version are you on? When I try this in the browser console at http://algebra.js.org/ it gets parsed and evaluated to "9" - which is not the correct evaluation but also not the Syntax Error you get.
Any workaround for this issue?
The workaround would be to wrap the negative number in brackets: algebra.parse('12 - (- 3)');
0.2.6
@timrach I wrapped them in brackets. Thanks
This:
algebrea.parse('12 -- 3');
Results in an error:
SyntaxError: Missing operand
After trying some other stuff, it appears it just can't handle negative signs after the operator. E.g. this also fails:
algebra.parse('-1 * -5');