Python之禅-小彩蛋

这是一篇英文的python之诗。

在cmd的python中输入 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. 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. 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. 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!

Python 之禅
Tim Peters 著
美比丑好,明比涩强。
简胜于繁,繁强于难。
平言莫绕,宜疏莫密。
行文如水,易懂为王。
勿提特例,皆循此规。
实虽胜纯,识错必究。
若需留证,亦要言明。
不明其理,追根问底。
必有一法,可解谜题。
汝非龟叔,求之故难。
立足当下,行必有方。
行难言喻,所思欠妥。
行易言表,所思可嘉。
名正易识,善莫大焉!

转自https://www.jianshu.com/p/237712de064e

传送去看翻译之美

点赞

发表评论

昵称和uid可以选填一个,填邮箱必填(留言回复后将会发邮件给你)
tips:输入uid可以快速获得你的昵称和头像