Runtime evaluation: Difference between revisions
Content added Content deleted
(add UNIX Shell) |
m (Added Sidef language) |
||
Line 1,005: | Line 1,005: | ||
(+ 4 5) ;; this is input from the user. |
(+ 4 5) ;; this is input from the user. |
||
9</lang> |
9</lang> |
||
=={{header|Sidef}}== |
|||
The eval method evaluates a string as code and returns the resulting object. |
|||
<lang ruby>var (a, b) = (-5, 7); |
|||
say eval '(a * b).abs'; # => 35 |
|||
say (a * b -> abs); # => 35</lang> |
|||
=={{header|Slate}}== |
=={{header|Slate}}== |