LAMBDA Expressions

A lambda-expression can be used to create an ``anonymous'' function (literally, one without a name); in general, a lambda-expression can be used where a function name is expected. The format of a lambda-expression is:


(lambda (args)  code)
A lambda-expression is ``quoted'' using the special form function, which can be abbreviated as #'.

(apply (function (lambda (x y) (+ x y)))
      '(2 3))

(apply #'(lambda (x y) (+ x y))
      '(2 3))
function or #' is analogous to quote or ', but is used instead of quote for lambda-expressions or function names.

Contents    Page-10    Prev    Next    Page+10    Index