+ 1
What is lamba expression?
Little cunfused when i use it
2 Respuestas
+ 1
It's the arrow thingy
(paramsHere) -> {code here;}
You can make semi functions with it, like compare function to sort elements the way you want.
Here's a code where I use them quite a bit as an example. getOperation returns a lambda expression which I use to get results for each element in range later on.
https://code.sololearn.com/cYyXfA2VNmK0/?ref=app