To share this page click on the buttons below;
Lambda functions
Lambda functin are small anonymous function defines as
lambda <arguments> : <function body>
Example that adds 10 to the argument passed
x = lambda a : a + 10
print(x(5))
Example that makes the multiplication of the arguments
x = lambda a, b : a * b
print(x(5, 6))
To share this page click on the buttons below;