Answers for "lambda python school"

1

lambda python

nums = [1, 2, 3, 4, 5]


print(list(map(lambda n:n*n, nums)))
#lambda n : n in this case is the passed value
Posted by: Guest on September-21-2021
1

lambda en python

doblar = lambda num: num*2

doblar(2)
Posted by: Guest on December-12-2020

Python Answers by Framework

Browse Popular Code Answers by Language