compile#
Parse and compile an expression. Returns a an object with a function evaluate([scope]) to evaluate the compiled expression.
Available in: math cells, REPL.
Syntax#
compile(expr)
compile([expr1, expr2, expr3, ...])
Arguments and behavior#
Returns a compiled expression object. Method access in cells is restricted; use evaluate for ordinary evaluation.
Example#
Edit the inputs, then use Run or Reset. Changes stay in this example.
Example
code1 = compile("sqrt(3^2 + 4^2)")Interactive examples could not load. You can still copy the expressions.
Expected result: {"evaluate": function}.