Information Technology Consulting Service

Welcome Guest Search | Active Topics | Members | Log In

Anonymous function Options · View
Posted: Tuesday, March 29, 2016 12:00:51 PM
Rank: Administration
Groups: Member

Joined: 3/24/2008
Posts: 2,808
Points: 5,600
Location: South Florida USA
Anonymous function


In computer programming, an anonymous function (also function literal or lambda abstraction) is a function definition that is not bound to an identifier. Anonymous functions are often:[1]
1.arguments being passed to higher-order functions, or
2.used for constructing the result of a higher-order function that needs to return a function.

If the function is only used once, or a limited number of times, an anonymous function may be syntactically lighter than using a named function. Anonymous functions are ubiquitous in functional programming languages and other languages with first-class functions, where they fulfill the same role for the function type as literals do for other data types.

Anonymous functions originate in the work of Alonzo Church in his invention of the lambda calculus in 1936 (prior to electronic computers), in which all functions are anonymous.[2] In several programming languages, anonymous functions are introduced using the keyword lambda, and anonymous functions are often referred to as lambdas or lambda abstractions. Anonymous functions have been a feature of programming languages since Lisp in 1958 and an increasing number of modern programming languages support anonymous functions.

Anonymous functions are a form of nested function, in allowing access to variables in the scope of the containing function (non-local variables). This means anonymous functions need to be implemented using closures. Unlike named nested functions, they cannot be recursive without the assistance of a fixpoint operator (also known as an anonymous fixpoint or anonymous recursion) or binding them to a name.[3]

Users browsing this topic

Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Main Forum RSS : RSS

SoClean Theme Created by Jaben Cargman (Tiny Gecko)
Powered by Yet Another version (NET v2.0) - 11/14/2007
Copyright © 2003-2006 Yet Another All rights reserved.
This page was generated in 0.033 seconds.