摘要: python作为一种脚本语言,我们用python写的各个module都可以包含以上那么一个累死c中的main函数,只不过python中的这种__main__与c中有一些区别,主要体现在: 1、当单独执行该module时,比如单独执行以上hello.py: python hello.py,则输出 可以 阅读全文
posted @ 2017-08-27 15:51 睡着的糖葫芦 阅读(206) 评论(0) 推荐(0) 编辑
摘要: 打印结果: 2193174953824 2193174953824 2193174953824 旺财 旺财 旺财 2193174953824 2193174953824 2193174953824 旺财 最后附上图便于理解 __new__方法的含义 旺财 最后附上图便于理解 __new__方法的含义 阅读全文
posted @ 2017-08-27 12:32 睡着的糖葫芦 阅读(2441) 评论(0) 推荐(0) 编辑
摘要: 打印结果: a1 a1 a1 a2 a2 a2 a3 a3 a3 3 3 3 hello world hello world hello world 阅读全文
posted @ 2017-08-27 10:56 睡着的糖葫芦 阅读(231) 评论(0) 推荐(0) 编辑