Jump to content

Anonymous function

From Simple English Wikipedia, the free encyclopedia
Revision as of 23:17, 16 April 2010 by PiRSquared17 (talk | changes) (Created page with 'In computing, an '''anonymous function''' is a function that has no name. ==Example in Python == <source lang="python". (lambda x: (lambda y: x * y)) </python> The above ...')
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

In computing, an anonymous function is a function that has no name.

Example in Python

<source lang="python". (lambda x: (lambda y: x * y)) </python>

The above code can be executed as a function:

<source lang="python". >>>(lambda x: (lambda y: x * y))(3)(4) 12 </python>