Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
### Build lambda function
lambda x: x + 1
### Build lambda function and assign it into one variable
add = lambda x: x + 1
print(add(5))
# > 6
### Build normal function
def add(x):
return x + 1
print(add(5))
# > 6
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.