Top "Lambda" questions

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

How do I define a method which takes a lambda as a parameter in Java 8?

In Java 8, methods can be created as Lambda expressions and can be passed by reference (with a little work under …

java lambda java-8
C# Lambda expressions: Why should I use them?

I have quickly read over the Microsoft Lambda Expression documentation. This kind of example has helped me to understand better, …

c# c#-3.0 lambda
Why would you use Expression<Func<T>> rather than Func<T>?

I understand lambdas and the Func and Action delegates. But expressions stump me. In what circumstances would you use an …

c# delegates lambda expression-trees
Filter values only if not null using lambda in Java8

I have a list of objects say car. I want to filter this list based on some parameter using Java 8. …

java lambda nullpointerexception null java-8
Retrieving Property name from lambda expression

Is there a better way to get the Property name when passed in via a lambda expression? Here is what …

c# linq lambda expression-trees
Does Java SE 8 have Pairs or Tuples?

I am playing around with lazy functional operations in Java SE 8, and I want to map an index i to …

java lambda functional-programming java-8 java-stream
Filter Java Stream to 1 and only 1 element

I am trying to use Java 8 Streams to find elements in a LinkedList. I want to guarantee, however, that there …

java lambda java-8 java-stream
How to perform Join between multiple tables in LINQ lambda

I am trying to perform a Join between multiple tables in LINQ. I have the following classes: Product {Id, ProdName, …

c# linq join lambda multiple-tables
Syntax behind sorted(key=lambda: ...)

I don't quite understand the syntax behind the sorted() argument: key=lambda variable: variable[0] Isn't lambda arbitrary? Why is variable …

python sorting lambda custom-function
forEach loop Java 8 for Map entry set

I'm trying to convert old conventional for each loop till java7 to java8's for each loop for a map …

java lambda java-8