摘要: 1 txt 读写 A txt读 B txt写 2 excel读写 (参考https://www.cnblogs.com/lingwang3/p/6416023.html) (参考https://www.cnblogs.com/sun-haiyu/p/7096423.html) 读一行数据:如果要获得 阅读全文
posted @ 2017-12-23 21:57 林雁1983 阅读(115) 评论(0) 推荐(0)
摘要: 1 字符串创建:var1 = 'Hello World!' 2 字符串不可变 3 单字符也在Python也是作为一个字符串使用 4 Python 访问子字符串,可以使用方括号来截取字符串 5 字符串转义:在需要在字符中使用特殊字符时,python用反斜杠(\)转义字符 6 字符串运算 + 字符串连接 阅读全文
posted @ 2017-12-16 23:40 林雁1983 阅读(354) 评论(0) 推荐(0)
摘要: num1 = [1,2,3,4,5,6] num2 = num1 print(id(num1)) print(id(num2)) 实际上两个id是一样的 num2 = num1.copy() # 可变变量:list,dict # 不可变变量:字符串,元组 阅读全文
posted @ 2017-12-14 19:34 林雁1983 阅读(146) 评论(0) 推荐(0)