What is the core principle of lambda expression in java?

4/27/2019 3:54:37 PM


2 Answers

New Answer


Here is an example code: https://code.sololearn.com/c5ZmQguR1rPp/?ref=app


Lambda expressions, which are also known as lambdas or closures, allow an object with a single method to be created with only an -> operator. Lambdas became a handy feature as it allowed to work with functional interfaces without creating a new method. Using lambdas could increase the efficiency and readability of the code. Also it can greatly minimize the lines of code. This feature was added in java 8 as it was a highly requested feature