- 博客(6)
- 收藏
- 关注
原创 Python记录-- 类初始化,默认参数使用list\dict等指针类型时的注意事项
如果一个类,默认初始化时,指定了默认参数A,且是 list 或dict 类型的,并且在你初始化时,没有显式指定该参数值,那么你会发现,不管这个类创建多少个对象,这些对象的A属性都是相同的。class MyClass: def __init__(self, name, mylist=[]): self.name = name self.mylist = ...
2020-02-27 19:19:24
729
原创 velocity使用+JavaMailSender发送邮件 简单示例
1、pom.xml 添加相关依赖 <dependency> <groupId>org.apache.velocity</groupId> <artifactId>velocity</artifactId> <version>1.6.4</version> &...
2019-09-29 15:59:33
508
原创 Mybatis 学习+经验积累(1)
Merge into + 注解 方式,批量更新或插入1、参数为List<Map> 类型示例:Dao中为 @Insert({"<script>merge into tblname a using ("+ "<foreach collection =\"list\" item=\"item\" index= \"index...
2019-08-16 11:17:48
170
原创 MATLAB读取txt的一些方法简单记录
文档内容是数字和字符混合的时(1)比如文档testReadData.txt 为1 a w 2 c 37 b d 8 e 93 f s 6 r 5m=3;n=6;data=cell(m,n);%定义cell矩阵,存储文件内容fid=fopen('D:\Projects\matlabproject\dailyPractice\tes
2015-10-16 10:07:32
2617
转载 MATLAB对于文本文件(txt)数据读取的技巧总结(经典中的经典)
特别说明:由于大家在 I/O 存取上以 txt 文件为主,且读取比存储更麻烦(存储的话 fwrite, fprintf 基本够用),因此下面的讨论主要集中在“txt 文件的读取”上。除了标注了“转”之外,其余心得均出于本人经验之结果,欢迎大家指正、补充。一. 基本知识:--------------------------------------------------转--------
2015-10-15 12:39:42
1080
原创 LaTeX 排版问题之算法设计
自己用LaTeX写的一个算法,需要用到的一些包\usepackage{algorithm} %format of the algorithm\usepackage{algorithmic} %format of the algorithm\usepackage{multirow} %multirow for format of table\usepackage{amsmath}
2015-08-21 13:00:38
1173
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅