I don't quite understand the second sentence here from The Zen of Python:
Now is better than never.
Although never is often better than right now.
Can anyone explain it or give an example?
The minimalistic design philosophy of Python means that it emphasizes code readability. It also provides a syntax structure that allows programmers to express concepts in fewer lines of code than in languages such as C++ and Java. Moreover, Python provides the means to write programs that can be scaled up easily.
The Zen of Python is a collection of 19 "guiding principles" for writing computer programs that influence the design of the Python programming language. Software engineer Tim Peters wrote this set of principles and posted it on the Python mailing list in 1999.
Thanks to his contribution, anyone can view the Zen straight from the Python interpreter by typing import this : >>> import this The Zen of Python, by Tim Peters Beautiful is better than ugly. Explicit is better than implicit. Simple is better than complex.
It is a two parter:
Now is better than never
Don't spend too much time planning and pre-optimising; get something down that does the job and iterate on it (or: fix that issue now rather than putting it off).
Never is often better than right now
But do put some thought into it, so you don't head off down a path that later means there's no graceful way back (see also: YAGNI).
I would imagine that the philosophy means that it is better to think of a solution rather than simply forestalling the inevitable (and causing problems later).
However, it is also better to think about what solution you will do first - don't write 'quick hacks' to solve the problem at hand.
So, It's best to fix that problem sooner rather than later, but don't immediately code whatever comes to mind, instead, think about that first and what ramifications your fix might have.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With