上一页 1 ··· 452 453 454 455 456 457 458 459 460 ··· 640 下一页
摘要: 打开文件 1.建立磁盘 上的文件与程序中的对象相关联 2.通过相关的文件对象获得 文件操作 (1)读取(2)写入(3)其他:追加、 ... 阅读全文
posted @ 2022-10-07 20:36 I'm_江河湖海 阅读(24) 评论(0) 推荐(0)
摘要: 数据保存的方式多种多样,最简单的形式是直接保存成文本文件,比如txt/json/csv…另外还可以保存到数据库----关系型数据库–... 阅读全文
posted @ 2022-10-07 20:36 I'm_江河湖海 阅读(12) 评论(0) 推荐(0)
摘要: operator模块提供的itemgetter函数用于获取对象的哪些维的数据,参数为一些序号,看下面例子: import opera... 阅读全文
posted @ 2022-10-07 20:36 I'm_江河湖海 阅读(18) 评论(0) 推荐(0)
摘要: operator模块提供的itemgetter函数用于获取对象的哪些维的数据,参数为一些序号,看下面例子: import opera... 阅读全文
posted @ 2022-10-07 20:36 I'm_江河湖海 阅读(21) 评论(0) 推荐(0)
摘要: property():返回新式类属性。 class property ( [fget [, fset [, fdel [, doc]... 阅读全文
posted @ 2022-10-07 20:36 I'm_江河湖海 阅读(12) 评论(0) 推荐(0)
摘要: property():返回新式类属性。 class property ( [fget [, fset [, fdel [, doc]... 阅读全文
posted @ 2022-10-07 20:36 I'm_江河湖海 阅读(16) 评论(0) 推荐(0)
摘要: 定义 直接赋值:就是对象的引用(别名)浅拷贝(copy):拷贝父对象,不拷贝对象内部的子对象深拷贝(deepcopy):copy模块... 阅读全文
posted @ 2022-10-07 20:36 I'm_江河湖海 阅读(27) 评论(0) 推荐(0)
摘要: 相同点: 两者是参数相同:dict.get(key, default=None), dict.setdefault(key, def... 阅读全文
posted @ 2022-10-07 20:36 I'm_江河湖海 阅读(13) 评论(0) 推荐(0)
摘要: 相同点: 两者是参数相同:dict.get(key, default=None), dict.setdefault(key, def... 阅读全文
posted @ 2022-10-07 20:36 I'm_江河湖海 阅读(27) 评论(0) 推荐(0)
摘要: 一. 什么是异常 python用异常对象(expection object)来表示异常情况。遇到错误后,会引发异常。如果是异常对象并... 阅读全文
posted @ 2022-10-07 20:36 I'm_江河湖海 阅读(14) 评论(0) 推荐(0)
上一页 1 ··· 452 453 454 455 456 457 458 459 460 ··· 640 下一页