commit message from python script
This commit is contained in:
9
test_skripte/comp_lampda_map.py
Normal file
9
test_skripte/comp_lampda_map.py
Normal file
@@ -0,0 +1,9 @@
|
||||
i = [2, 4, 6, 8 , 10 ]
|
||||
|
||||
# List comprehension
|
||||
test = [x * 2 for x in i]
|
||||
# lampda function
|
||||
lam_test = list(map(lambda x: x * 3, i))
|
||||
print(i)
|
||||
print(test)
|
||||
print(lam_test)
|
||||
Reference in New Issue
Block a user