Re:Hy – A Lisp-flavored Python
by kbp on Thursday August 03, 2017 @01:42PM
(#14921822)
Logo lets you leave out parentheses most of the time, except to use rest arguments or force grouping. For example:
That expression parses as (print (list (sum 0 1) 2)) because both list and sum normally take 2 arguments. However, using the parenthesised function call syntax, you can pass them however many you like:
Or you can of course mix and match (probably to better effect than this example):
Logo also lets you use infix arithmetic operators with normal precedence:
[ Parent
| on HN ]
I love Logo! Advanced Logo by Michael Friendly is one of my programming books.
Logo came very close to TN and ETNs but adding the parens and other visible syntax I believe was a design mistake. It's not obvious, but when working with large programs in 2 and 3 dimensions (only possible with parens free lisp, or ETNs as we call them), you gain tremendous productivity benefits