摘要: 原则 减少数据扫描 返回更少数据 减少交互次数 减少服务器CPU和内存开销 方法 避免使用select * 小表驱动大表 使用limit 百万级别表翻页 union all 代替 union join 表不宜过多 连接查询代替子查询(不适用所有 具体分析) group by 字段建立索引 阅读全文
posted @ 2024-10-08 16:20 莫大师兄 阅读(10) 评论(0) 推荐(0)
摘要: 模型数空运最快哦 1.模糊查询%在左边, 数据类型不对 数学运算 空值null 函数运算 最左匹配原则 不用索引查询已经很快乐 or 其中一端不用索引 阅读全文
posted @ 2024-10-08 14:37 莫大师兄 阅读(5) 评论(0) 推荐(0)
摘要: 面试题 Q:什么时候需要手动进行垃圾回收 A:解决循环引用导致垃圾回收失败问题 https://blog.csdn.net/Enjolras_fuu/article/details/102464258 python 基础内存管理 引用计数 垃圾回收机制--分代 手动管理 gc模块(配合 putil) 阅读全文
posted @ 2024-09-30 17:06 莫大师兄 阅读(11) 评论(0) 推荐(0)
摘要: 参考:https://blog.csdn.net/LB_AUTO/article/details/106041858#MySQL_2 版本做了改变 VERSION:8.4.2 安装后首次更改密码不成功原因:https://www.tubring.cn/articles/fix-php-mysql-8 阅读全文
posted @ 2024-09-23 20:33 莫大师兄 阅读(105) 评论(0) 推荐(0)
摘要: math 模块 math.ceil() 向上取整 math.floor() 向下取整 ``` # 导入 math 包 import math # 输出向下舍入到最接近的整数 print(math.floor(0.6)) print(math.floor(1.4)) print(math.floor( 阅读全文
posted @ 2023-08-08 00:00 莫大师兄 阅读(100) 评论(0) 推荐(0)
摘要: 找出转圈游戏输家 my solution 100% pass class Solution: def circularGameLosers(self, n: int, k: int) -> List[int]: seen = set() now_num = 1 step = 1 seen.add(1 阅读全文
posted @ 2023-05-15 09:24 莫大师兄 阅读(16) 评论(0) 推荐(0)
摘要: 6430. 找出转圈游戏输家 my solution 100% pass class Solution: def circularGameLosers(self, n: int, k: int) -> List[int]: seen = set() now_num = 1 step = 1 seen 阅读全文
posted @ 2023-05-14 11:51 莫大师兄 阅读(21) 评论(0) 推荐(0)
摘要: https://blog.csdn.net/qq_42332950/article/details/119945837 阅读全文
posted @ 2023-05-09 23:35 莫大师兄 阅读(28) 评论(0) 推荐(0)
摘要: https://stackoverflow.com/questions/64724782/pip-install-error-microsoft-visual-c-14-0-or-greater-is-required Download and install Microsoft Visual St 阅读全文
posted @ 2023-04-25 08:04 莫大师兄 阅读(48) 评论(0) 推荐(0)
摘要: https://zhuanlan.zhihu.com/p/128809461 阅读全文
posted @ 2023-04-17 10:44 莫大师兄 阅读(10) 评论(0) 推荐(0)