Closed tomer-ben-david closed 9 months ago
That's partly because end
is a reserved keyword in Math.js, I believe. The following works:
start = 1673546301
end_ = 1673627599
end_ - start
And I think that it doesn't work in your screenshot (where you use startDate
and endDate
) because the minus isn't actually a minus sign but an en-dash or em-dash.
It would be nice to have a Lezer grammar for the Math.js syntax to have syntax highlighting for reserved keywords and constants. In this case, end
would then have been highlighted, and it would have been easier to understand what was going on.
It would be nice to have a Lezer grammar for the Math.js syntax to have syntax highlighting for reserved keywords and constants
Created an issue for that here: #160
Describe the bug I subtracted one variable from another in math block and don't see the answer.
To Reproduce Create a new math block and put this in:
start = 1673546301 end = 1673627599
t = end − start
t will have no result value.
Expected behavior t will have the result value of the subtraction.
Screenshots
Desktop (please complete the following information): MacOs Version 1.6.0
Additional context Add any other context about the problem here.