移花接木2021-08-07 22:11:03

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. Peters's list left open a 20th principle "for Guido to fill in", referring to Guido van Rossum, the original author of the Python language. The vacancy for a 20th principle has not been filled.

Peters's Zen of Python was included as entry number 20 in the language's official Python Enhancement Proposals and was released into the public domain. It is also included as an Easter egg in the Python interpreter, where it can be displayed by entering import this.

In May 2020, Barry Warsaw wrote the lyrics to music.

 

Zen of Python by Tim Peters

Beautiful is better than ugly.
Explicit is better than implicit.
Simple is better than complex.
Complex is better than complicated.
Flat is better than nested.
Sparse is better than dense.
Readability counts.
Special cases aren't special enough to break the rules.
Although practicality beats purity.
Errors should never pass silently.
Unless explicitly silenced.
In the face of ambiguity, refuse the temptation to guess.
There should be one— and preferably only one —obvious way to do it.[a]
Although that way may not be obvious at first unless you're Dutch.
Now is better than never.
Although never is often better than right now.[b]
If the implementation is hard to explain, it's a bad idea.
If the implementation is easy to explain, it may be a good idea.
Namespaces are one honking great idea—let's do more of those!

beautifulwind2021-08-07 23:09:55
是啊,计算机语言也是语言,也是歌词!编曲配器听着很酷!
移花接木2021-08-07 23:22:41
音乐响起,恍惚间我觉得是枫老师的作品, 这首押韵的编程规则很酷,写了19条还留下一条等人填上去。
欲借嵯峨2021-08-07 23:30:20
这歌词写得太棒了!
Lily20052021-08-08 02:47:00
My favorite “If the implementation is hard to explain, it's a ba
天山晨2021-08-08 03:19:46
这歌酷,确实如此,我一直追求越简单越好,哈哈!
LYJiang2021-08-08 04:11:55
PYTHON = (P)rogrammers (Y)earning (T)o (H)omestead (O)ur (N)oosp
盈盈一笑间2021-08-08 18:23:15
IT guy...haha , how about C++?
移花接木2021-08-09 00:18:16
I'm 2 old 2 C#
Lily20052021-08-09 04:21:59
C# will be 2 easy for you.
移花接木2021-08-09 04:27:28
need reading glasses, 老花镜
甜虫虫2021-08-09 16:35:33
Philosophical :) Great!