Skip to content
TurtleKitty edited this page May 12, 2019 · 2 revisions

_

This operator creates a function of one argument, _.
(_ ...) is syntactic sugar for (lambda (_) ...).

(list
    ((_ (+ _ _)) 1)
    ((_ (* 5 _)) 2)
    ((_ (* _ _)) 3))

; (2 10 9)

For fans of Morse code: _ functions can be nested.

((_ (+ _ ((_ (* _ _)) 3))) 7) ; 16
Clone this wiki locally