We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b2314f4 commit e04ea89Copy full SHA for e04ea89
README.md
@@ -37,7 +37,7 @@ sum_of_elements = sum(<list>)
37
elementwise_sum = [sum(pair) for pair in zip(list_a, list_b)]
38
sorted_by_second = sorted(<list>, key=lambda el: el[1])
39
sorted_by_both = sorted(<list>, key=lambda el: (el[1], el[0]))
40
-flattened_list = [item for sublist in <list> for item in sublist]
+flattened_list = list(itertools.chain.from_iterable(<list>))
41
list_of_chars = list(<str>)
42
product_of_elems = functools.reduce(lambda out, x: out * x, <list>)
43
```
0 commit comments