Top "Lambda" questions

DO NOT USE FOR THE AWS SERVICE (use [aws-lambda] for those questions!

Assignment inside lambda expression in Python

I have a list of objects and I want to remove all objects that are empty except for one, using …

python lambda expression variable-assignment
What are functional interfaces used for in Java 8?

I came across a new term in Java 8: "functional interface". I could only find one use of it while working …

java lambda interface java-8
Combining two expressions (Expression<Func<T, bool>>)

I have two expressions of type Expression<Func<T, bool>> and I want to take to …

c# linq lambda expression
Is there a reason for C#'s reuse of the variable in a foreach?

When using lambda expressions or anonymous methods in C#, we have to be wary of the access to modified closure …

c# foreach lambda scope anonymous-methods
Explicit Return Type of Lambda

When I try and compile this code (VS2010) I am getting the following error: error C3499: a lambda that has …

c++ visual-c++ lambda c++11 visual-c++-2012
Java 8 Filter Array Using Lambda

I have a double[] and I want to filter out (create a new array without) negative values in one line …

java lambda java-8
List<object>.RemoveAll - How to create an appropriate Predicate

This is a bit of noob question - I'm still fairly new to C# and generics and completely new to …

c# generics delegates lambda predicate
Can lambda functions be templated?

In C++11, is there a way to template a lambda function? Or is it inherently too specific to be templated? …

c++ templates lambda c++11
How to merge a list of lists with same type of items to a single list of items?

The question is confusing, but it is much more clear as described in the following codes: List<List<…

c# linq lambda
When should I use Arrow functions in ECMAScript 6?

The question is directed at people who have thought about code style in the context of the upcoming ECMAScript 6 (Harmony) …

javascript lambda ecmascript-6 ecmascript-harmony arrow-functions