摘要: #enumerate#seasons=['spring','summer','autumn','winter']seasons=('spring','summer','autumn','winter') # env tuple is works ,but after ... 阅读全文
posted @ 2017-04-01 19:27 yuerspring 阅读(69) 评论(0) 推荐(0) 编辑
摘要: #using Decorators not understand reallyimport operatorclass Files: def __init__(self,**kwargs): self.properties =kwargs ... 阅读全文
posted @ 2017-04-01 18:14 yuerspring 阅读(62) 评论(0) 推荐(0) 编辑
摘要: #exception handling of Python#how to do with the exception just like java#raising exceptions#multiple exceptions#geniric exception#ig... 阅读全文
posted @ 2017-04-01 17:03 yuerspring 阅读(100) 评论(0) 推荐(0) 编辑
摘要: #! usr/bin/python# #coding=utf-8 # for chinese#overview of classes and Methodsclass data(object): print __name__ def __init__... 阅读全文
posted @ 2017-04-01 15:28 yuerspring 阅读(99) 评论(0) 推荐(0) 编辑
摘要: from operator import itemgetter,attrgetterdef main(): #range function mynms =list(range(10,20,2)) print mynms print sorted... 阅读全文
posted @ 2017-04-01 13:40 yuerspring 阅读(128) 评论(0) 推荐(0) 编辑