4 ms·
>"Consider this Scheme expression, taken from the Rosetta Code example for the Mandelbrot set: (boolean->integer (inside? (make-rectangular (+ x-offset
by peter_d_sherman 5y ago
>"Consider this Scheme expression, taken from the Rosetta Code example for the Mandelbrot set:
(boolean->integer
(inside?
(make-rectangular (+ x-offset (\* pixel-size i))
(- y-offset (\* pixel-size j))))
[...]
Stack languages are a mirror image of Lisps, written in postfix rather than prefix notation.
So a Forth-like version of this expression would be the same words in reverse, without the parentheses:
j pixel-size * y-offset -
i pixel-size * x-offset +
make-rectangular inside? boolean->integer"
PDS: I know about both LISP and Forth -- but until I read this article, I never made this simple, intuitive, elegant, and utterly brilliant -- connection!
Yes, it's absolutely true!
And it's utterly, utterly brilliant!!!
To the Author: Thank you for writing this article!!!