python奥义
2015-12-17 10:41
531 查看
键入下面代码:
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奥义
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奥义
相关文章推荐
- python 发送邮件
- python base64编码的应用
- python unicode字符串
- 解决python安装selenium报错问题ImportError: No module named 'selenium'
- Python的字典操作
- python知识-列表生成式
- python中创建字典的方法和迭代字典的方法
- python装饰器的wraps作用
- 从排列与组合的python实现到"生日问题"的解释
- python获取命令行输出结果
- python知识—切片/迭代
- python socket编程详细介绍
- 使用python,scrapy写(定制)爬虫的经验,资料,杂。
- 介绍几款Python IDE
- python 线程及线程池
- python输出1到100之和的几种方法
- python-61: Beautiful Soup 4
- window64位下python2.7安装Twisted
- python中print不换行的方法
- Python获取脚本所在路径的方法