http://meetbill.github.io/
发布时间:2016-04-24 18:29:56
Python类的用法第一种方法:全选复制放进笔记class OneObjectCreater(): pass第二种方法带有类的参数全选复制放进笔记class TwoObjectCreater(object): pass都使用print出来,却有细微的差别;全选复制放进笔记if __name__ == "__main__": print OneObjectCreater() print TwoObjectC.........【阅读全文】
发布时间:2016-03-28 22:15:28
装饰器是程序开发中经常会用到的一个功能,用好了装饰器,开发效率如虎添翼,所以这也是Python面试中必问的问题,但对于好多小白来讲,这个功能 有点绕,自学时直接绕过去了,然后面试问到了就挂了,因为装饰器是程序开发的基础知识,这个都 不会,别跟人家说你会Python, 看了下面的文章,保证你学会装饰器。1、先明.........【阅读全文】
发布时间:2016-03-17 21:07:02
Python’s with statement provides a very convenient way of dealing with the situation where you have to do a setup and teardown to make something happen. A very good example for this is the situation where you want to gain a handler to a file, read data from the file and the close the file handler..........【阅读全文】