4 ms·
(let* ([x (+ 1 2)] [y (+ x 3)]) (* x y)) Less ambiguity, all of the clarity of what is what. I don't get why you use other delimiters for your
by 59nadir 11y ago
(let* ([x (+ 1 2)]
[y (+ x 3)])
(* x y))
Less ambiguity, all of the clarity of what is what. I don't get why you use other delimiters for your Clojure code, but have this view that they can't be used in other Lisps/Schemes.
(You will also have to use `let*` in (most?) schemes because the binding for y has absolutely nothing to do with the binding for x and so cannot be used in the binding of y.)
- moonchrome 11y ago>I don't get why you use other delimiters for your Clojure code Do other delimiters mean the same thing as in Clojure tho ? I only know Clojure - in Clojure [] - vector- is a different data structure from () - linked list - which is different from {} - hash map. Is this similar to Racket or is it all just lists in Racket ?
- klibertp 11y agoIn Racket all kinds of parenthesis are equivalent, using one or the other is a matter of convention and readability. I think the newest Scheme standard takes the same approach.