補充些Python方面的文化,文章翻譯自http://legacy.python.org/dev/peps/pep-0020/ 同步於 http://polarisary.github.io/2014/07/01/the-zen-of-python/python
Beautiful is better than ugly.
bash 整潔勝於雜亂
git
Explicit is better than implicit.
bash 明瞭勝於隱晦
github
Simple is better than complex.
bash 簡單勝於複雜
bash
Complex is better than complicated.
bash 複雜勝於混亂
less
Flat is better than nested.
bash 遞推勝於嵌套
`ide
Sparse is better than dense.
bash 稀疏勝於稠密
ui
Readability counts.
bash 可讀性是最重要的---易讀
idea
Special cases aren't special enough to break the rules.
bash 特例不足以打破規則
spa
Although practicality beats purity.
bash 可是,實用性勝於純粹套用
翻譯
Errors should never pass silently.
bash 錯誤不該該不報
Unless explicitly silenced.
bash 除非另有明確的目的
In the face of ambiguity, refuse the temptation to guess.
bash 不清楚的,不能去猜
There should be one-- and preferably only one --obvious way to do it.
bash 總會有一種方式來解決問題,而且一般只有一種
Although that way may not be obvious at first unless you're Dutch.
bash 然而,這種解決問題的方式在一開始不是那麼的明瞭,除非你有先見之明
Now is better than never.
bash 如今,有一種不明瞭的解決方案比歷來沒有好
Although never is often better than right now.
bash 然而,倉促的解決否則沒有
If the implementation is hard to explain, it's a bad idea.
bash 若是方案不明確,就是個壞的想法
If the implementation is easy to explain, it may be a good idea.
bash 相反,則是個好的主意
Namespaces are one honking great idea -- let's do more of those!
bash 名字空間是個好的設計,咱們應該好好的使用它