上一页 1 ··· 5 6 7 8 9 10 11 12 13 下一页
摘要: # 具名元组>>> from collections import namedtuple >>> City = namedtuple('City', 'name country population coordinates') ➊ >>> tokyo = City('Tokyo', 'JP', 36 阅读全文
posted @ 2021-06-07 14:07 小毛编 阅读(22) 评论(0) 推荐(0) 编辑
摘要: 小结 # 简单的赋值不创建副本。 # 对 += 或 *= 所做的增量赋值来说,如果左边的变量绑定的是不可变对象,会创建新对象;如果是可变对象,会就地修改。 # 为现有的变量赋予新值,不会修改之前绑定的变量。这叫重新绑定:现在变量绑定了其他对象。如果变量是之前那个对象的最后一个引用,对象会被当作垃圾回 阅读全文
posted @ 2021-06-02 20:28 小毛编 阅读(49) 评论(0) 推荐(0) 编辑
摘要: ***物理端口:设备的接口 ***逻辑端口:一般是指TCP/IP协议中的端口,端口号的范围从0到65535,比如用于浏览网页服务的80端口,用于FTP服务的21端口等等。 端口简介 端口(Port)大致有两种意思:一是物理意义上的端口,比如,ADSL Modem、集线器、交换机、路由器用于连接其他网 阅读全文
posted @ 2021-06-02 08:08 小毛编 阅读(362) 评论(0) 推荐(0) 编辑
摘要: 回调式异步编程: 函数式编程: ### 装饰器基础 装饰器是可调用的对象,其参数是另一个函数(被装饰的函数)。 装饰器可能: 1)将其替换成另一个函数或可调用对象 ## 替换成其他函数def deco(func): def inner(): print('running inner()') # pr 阅读全文
posted @ 2021-06-01 11:28 小毛编 阅读(60) 评论(0) 推荐(0) 编辑
摘要: len():容器中项目数量 Return the length (the number of items) of an object. The argument may be a sequence (string, tuple or list) or a mapping (dictionary). 阅读全文
posted @ 2021-05-26 15:03 小毛编 阅读(1421) 评论(0) 推荐(0) 编辑
摘要: 总结:推荐使用xlwings 转自 :https://zhuanlan.zhihu.com/p/23998083 ​ xlwings http://docs.xlwings.org/en/stable/ openpyxl https://openpyxl.readthedocs.io/en/late 阅读全文
posted @ 2021-05-25 11:36 小毛编 阅读(457) 评论(0) 推荐(0) 编辑
摘要: import threading import inspect import ctypes def _async_raise(tid, exctype): """raises the exception, performs cleanup if needed""" if not inspect.is 阅读全文
posted @ 2021-03-13 16:40 小毛编 阅读(362) 评论(0) 推荐(0) 编辑
摘要: ValueError: substring not found还以为是代码出了问题,最后查阅文档: “Python index() rindex() 方法检测字符串中是否包含子字符串 str ,如果指定 beg(开始) 和 end(结束) 范围,则检查是否包含在指定范围内,该方法与 python f 阅读全文
posted @ 2021-03-13 15:46 小毛编 阅读(12086) 评论(0) 推荐(1) 编辑
摘要: 20:52 Gradle sync failed: A build operation failed. org.gradle.api.GradleException: Couldn't read file content: 'C:\Users\a20331\.gradle\caches\transf 阅读全文
posted @ 2021-03-11 21:01 小毛编 阅读(1751) 评论(1) 推荐(0) 编辑
摘要: 参考资料:https://blog.csdn.net/a_zhon/article/details/100569489 数据中转:https://blog.csdn.net/weixin_42112064/article/details/103835907 阅读全文
posted @ 2021-03-08 18:13 小毛编 阅读(385) 评论(0) 推荐(0) 编辑
上一页 1 ··· 5 6 7 8 9 10 11 12 13 下一页