DEV Community

loading...

Python Zen vs Perl TMTOWTDI

Yuki Kimoto
Perl and Mojolicious
・1 min read

Perl has been said to be a writing-only language for over a decade(Although In fact, it's a lie.).

Only Python Zen was evaluated.

Age has moved forward.

People want diversity and inclusion.

Perl TMTOWTDI means "There's more than one way to do it".

This message contains the philosophy of diversity and inclusion.

I hope the time will come when Perl's philosophy will be evaluated fairly.

Discussion (3)

Collapse
jafd profile image
Yaroslav Fedevych

The problem with TIMTOWTDI is that it inevitably devolves into developers using all ways.

Get a sizable codebase going, and your 100 dependencies are going to bring in 15 OO frameworks, 3 modules to deal with date and time, 4 async frameworks working "under the hood" and you're left alone to deal with all the overhead and philosophy clashes.

Contrast this with Python where, while there are multiple high-level projects with the same purpose (applications, web frameworks, libraries), there is only one of the "core" concepts, like OO or generators or (since recently) asynchronous programming — and everything is expected to boil down to those and play nice.

A recent example from my own Perl experience is that Devel::NYTProf broke attribute handlers in my codebase. I've spent days chasing a bug that turned out to not be in my own codebase.

"There's More than One Way to Do It" is only good when there is also a boundary to it, past which everything is done in a standard way. Imagine diversity and inclusion on a public road where half of the drivers choose to drive on the right and half on the left.

Collapse
hanpari profile image
Pavel Morava

If you ask about my opinion, then the Perl's motto feels like a design error to me.

Even though I am not a proponent of GoLang, Google's approach to this language indicates that a modern language design sticks rather with Python's than Perl's sentiment.

I guess people in Google are smart enough to recognize the right way.

It is quite funny for me to say this since their Dart or GoLang does not impress me much 😉

Collapse
yukikimoto profile image
Yuki Kimoto Author

Again today, I wrote a Perl article, but the only one that appeared in next read was a Python article.

I'm having trouble with over-advertising in Python.