- 博客(3)
- 收藏
- 关注
转载 python编码风格pep8
python:pep8 目录 PEP8中文翻译 什么是PEP PEP8 简介 愚蠢的一致性就像没有脑子的妖怪 代码布局 表达式与语句中的空白符 注释 版本注记 PEP8中文翻译 本文仅代表个人认知、观点、经验,May be Stupid! 什么是PEP PEP是 Python E
2015-12-13 20:55:51
591
原创 Python getattr()方法
getattr 基本概念 getattr提供了一种通过方法名来获取方法的一种途径,python官方的解释如下: getattr(object,name[,default]) Return the value of the namedattribute of object.namemust be a string. If the string is the name of one o
2015-09-08 22:03:37
813
原创 Python的方法
classMyClass(object): defmyNoActionMethod(self): pass Python的方法 方法的定义: 作为类的一部分被定义的函数称为方法,是类的两个属性——数据属性和方法之一。如下: myNoActionMethod即为方法。 方法的分类: 绑定方法和非绑定方法:
2015-09-06 21:24:46
476
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人