会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
菜鸟需勤奋
博客园
首页
新随笔
联系
订阅
管理
上一页
1
2
3
4
5
6
···
48
下一页
2025年11月13日
闭包&装饰器
摘要: def check(fn): def inner(x,y): print('验证登录',x,y) fn(x,y) return inner @check def comment(x,y): print("发表评论",x,y) if __name__ == '__main__': comment(10
阅读全文
posted @ 2025-11-13 14:25 iTao0128
阅读(6)
评论(0)
推荐(0)
2025年11月12日
对象转字典列表&&字典转对象
摘要: import os class Student: stu_list = [] def __init__(self, name, age, phone): self.name = name self.age = age self.phone = phone def __str__(self): ret
阅读全文
posted @ 2025-11-12 14:25 iTao0128
阅读(9)
评论(0)
推荐(0)
2025年11月3日
递归
摘要: def welcome(n): if n>1: welcome(n-1) print(f"你好啊{n}") welcome(5) n=5时,判断n>1,进入递归,第4行代码进入待执行栈结构中 .... n=2时,判断n>1,条件成立,第4行代码进入待执行栈结构中("你好啊2") n=1时,判断n>1
阅读全文
posted @ 2025-11-03 22:46 iTao0128
阅读(7)
评论(0)
推荐(0)
python常用文档资料
摘要: python中的内置函数: https://docs.python.org/zh-cn/3.13/library/functions.html python中的模块: https://docs.python.org/zh-cn/3.13/py-modindex.html
阅读全文
posted @ 2025-11-03 11:12 iTao0128
阅读(12)
评论(0)
推荐(0)
2025年10月31日
字符串格式化
摘要: name = "zhang" age = 20 weight = 55.5 result = "我是%s,今年%i岁,体重:%s" % (name, age, weight) # 推荐使用下面的方法 info = f"我是{name},今年{age}岁,体重:{weight}" print(resu
阅读全文
posted @ 2025-10-31 16:29 iTao0128
阅读(2)
评论(0)
推荐(0)
2025年9月24日
mysql慢sql配置
摘要: mysql中my.ini或my.cfg文件
阅读全文
posted @ 2025-09-24 21:18 iTao0128
阅读(8)
评论(0)
推荐(0)
读取zip包中的文件
摘要: private List<String> readFile(String zipFilePath,String fileName){ File file = new File(zipFilePath); List<String> list; System.out.println(file.getNa
阅读全文
posted @ 2025-09-24 18:00 iTao0128
阅读(11)
评论(0)
推荐(0)
2025年9月21日
springboot2整合dynamic-datasource-spring-boot-starter多数据源
摘要: 添加依赖 首先,在你的 pom.xml 中添加 dynamic-datasource-spring-boot-starter 依赖。建议使用较新的版本,例如: <dependency> <groupId>com.baomidou</groupId> <artifactId>dynamic-datas
阅读全文
posted @ 2025-09-21 22:11 iTao0128
阅读(558)
评论(0)
推荐(0)
使用jdbcTemplate查询数据库
摘要: springboot2版本项目中已经整合了mybatis框架,yml文件中配置好了数据源, 现在想再使用jdbcTemplate查询另外一个数据库,需要怎么配置 # 这是你现有的MyBatis数据源配置(假设使用默认前缀) spring: datasource: url: jdbc:mysql://
阅读全文
posted @ 2025-09-21 21:53 iTao0128
阅读(42)
评论(0)
推荐(0)
2025年9月20日
springboot2整合mybatis
摘要: pom.xml <dependency> <groupId>org.mybatis.spring.boot</groupId> <artifactId>mybatis-spring-boot-starter</artifactId> <version>2.1.4</version> </depend
阅读全文
posted @ 2025-09-20 17:29 iTao0128
阅读(9)
评论(0)
推荐(0)
上一页
1
2
3
4
5
6
···
48
下一页
公告