Ask HN: What should be added to the syntax of Python and why?

https://news.ycombinator.com/item?id=36949508
by behnamoh • 3 years ago
6 11 3 years ago

I recently came across the pipe library [0] which allows function chaining in a much more straightforward way:

    sum(fib() | where(lambda x: x % 2 == 0) | take_while(lambda x: x < 4000000))
I know in Lisp languages you can extend the syntax easily, but I was wondering if there are any needs for that in Python.

[0] https://pypi.org/project/pipe/

Related Stories

Loading related stories...

Source preview

news.ycombinator.com