摘要:
class CCC: @property def aa(self): print(123) CCC().aa 还有个函数 是给变成变量调用的函数(因为函数加了@property,就不可以传参进去了) , 赋值用的装饰器函数@xxx.setter 参考: https://www.cnblogs.com 阅读全文
posted @ 2020-05-14 23:11
凯宾斯基
阅读(313)
评论(0)
推荐(0)
摘要:
参考: https://www.runoob.com/python/python-func-filter.html 有可能输出有问题 最后输出改成 print( list(newlist) ) 其他例子(判断变量是否为空): a=3b=4 print (list(filter(lambda X: T 阅读全文
posted @ 2020-05-14 22:45
凯宾斯基
阅读(505)
评论(0)
推荐(0)
摘要:
方法一: 执行类下面的 测试case if __name__ == '__main__': suiteTest = unittest.TestSuite() suiteTest.addTest(TestAuto("testCase_001")) suiteTest.addTest(TestAuto( 阅读全文
posted @ 2020-05-14 10:55
凯宾斯基
阅读(186)
评论(1)
推荐(0)
摘要:
import sys @ app.route('/ button /') def button_clicked(): print ('Hello world!',file = sys.stderr ) return redirect('/ ') 阅读全文
posted @ 2020-05-14 01:15
凯宾斯基
阅读(371)
评论(0)
推荐(0)

浙公网安备 33010602011771号