3 ms·
Perl has much less footguns than bash, it is also more powerful and faster. No language I am aware of have more footguns than bash, with the exception of some
by GuB-42 4y ago
Perl has much less footguns than bash, it is also more powerful and faster.
No language I am aware of have more footguns than bash, with the exception of some other Unix shells.
But really, I really like Perl for throwaway scripts and one-liners. Because of its syntax, Python essentially can't do one-liners, and generally, Perl code is shorter and quicker to write assuming you are experienced in both languages.
But I agree that readability is terrible unless you are really careful. When my Perl scripts get a bit too big, slow, and less "throwaway", I tend to rewrite them in another language. Often C or C++ because I know these well but I guess that Go can work too.
Python has some great features, it is simple and code is naturally readable, but for me it sits on an uncomfortable spot: not permissive enough for quick, throwaway code, and too permissive and slow for larger, maintained projects.