Hacker Timesnew | past | comments | ask | show | jobs | submitlogin

A pipe merely "pipes" the output of one function as an input to another. For example, | in bash. In Python this can be done the trivial way (by composing) or by using decorators.


Yes, it can be done the trivial way in most languages. For deep nestung, that's ugly and awkward, which is why some languages have piping/composition operators [or threading macros] (sometimes more than one). Python has no close equivalent of a piping operator or threading macro (decorators don't seem helpful at all here.)




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: