45 ms·
With a small reminder that the pythonic way to do filter and map is even more readable - but it's limited in scope: [x * 3 for x in [1, 2, 3, 4] if x % 2 ==
by kzrdude 3y ago
With a small reminder that the pythonic way to do filter and map is even more readable - but it's limited in scope:
[x * 3 for x in [1, 2, 3, 4] if x % 2 == 0]
with that said, I still love the general concept of chaining, and I use that style a lot where it is already convenient and popular - in pandas code.