Skip to content

Commit 9a7bbb0

Browse files
committed
Functional add more
1 parent f08a94a commit 9a7bbb0

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed

functional_program/functional_sequence_operate/functional_filter.py

Whitespace-only changes.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
l = [1, 2, 3, None, 4, 5, 6]
2+
print(
3+
list(iter(l.pop, None))
4+
)
5+
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
import itertools
2+
3+
res = itertools.starmap(lambda x, y: x + y, zip([1, 2, 3], [4, 5, 6]))
4+
print([item for item in res])
5+
6+
res2 = map(lambda x, y: x + y, [1, 2, 3], [4, 5, 6])
7+
print([item for item in res2])
8+

0 commit comments

Comments
 (0)