Created
November 8, 2022 16:33
-
-
Save werterzz/73d6316f4e4ec5c5452478c4a15aac8f to your computer and use it in GitHub Desktop.
create grill function receive 1 argument
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# create grill function receive 1 argument | |
grill = lambda food: "grilled " + food | |
print(grill('beef')) | |
# output: grilled beef | |
# create cook function receive 2 arguments | |
cook = lambda cook, food: cook + " " + food | |
print(cook("boil", "egg")) | |
# output: boil egg |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment