30 ms·
I see they use they use the actual lambda character "λ" to create functions which is both cool and also probably makes grepping for functions a PITA. It does lo
by gleenn 2y ago
I see they use they use the actual lambda character "λ" to create functions which is both cool and also probably makes grepping for functions a PITA. It does look pretty but I would have to search the web or write down the random keystroke to generate that symbol.
An example usage:
(filter
(quicksort '(5 40 1 -3 2) <)
(λ (x) (>= x 0)))
- deleted 2y ago[deleted]
- codr7 2y agoFunctions deserve their own symbol in Lisp. Though I prefer ^ since it’s easier to type. https://github.com/codr7/sharpl https://github.com/codr7/sharpl
- satvikpendem 2y agoHaskell uses \ which is nice, it's an ASCII character that looks like the right half of λ
- darby_nine 2y agoIt's pretty common to wire \ to the lambda character in your editor. I think racket already allows this (if not as a replacement for lambda, an alternative syntax for it)
- gylterud 2y agoThis is also what Agda does (though \ is synonymous).
- brudgers 2y agoYou can use a λ in many common Rackets.
- cryptocod3 2y agoThe language supports both (λ is just an alias... which I might remove) Replaced the example with lambda - appreciate the feedback!