[racket] What is the equivalent of ToExpression in Mathematica?
On 2/29/12 4:33 PM, Ashok Bakthavathsalam wrote:
> Will eval-string work even if the string is the normal mathematical
> notation?
> For example, "1+1" or "8*74-2" ?
No, Racket is doing what Mathematica does. Mathematica interprets the
string as an expression written in Mathematica, just as Racket
interprets the string as an expression written in Racket.
(Mathematica notation just happens to be closer to what math often looks
like for very simple cases.)
If you want to use a different notation, you need a parser for that
notation, and Racket includes tools for writing parsers.
David