The lambda anonymous function is part of PHP 5.3. What use does it have? Is there anything that one can only do with lambda? Is lambda better for certain tasks?
I\'
Despite all of the uses one can think for lambda functions, in PHP it also allows something very special called closure. That is the ability to make variables in the current scope available to the function long after the current scope stops existing.
Just to mention some useful patterns that closure allow you, one can implement Memoization (Caching) and Curry.
Also very useful are the throw-away or callback functions that @Matt highlighted in his answer.
For more on closures, check this question: How do JavaScript closures work?