第1章 判断集合元素唯一的原理 1.1 ArrayList的contains方法判断元素是否重复原理 ArrayList的contains方法会使用调用方法时,传入的元素调用equals方法依次与集合中的旧元素所比较,从而根据返回的布尔值判断是否有重复元素。此时,当ArrayList存放自定义类型时 ...
分类:
编程语言 时间:
2020-01-03 23:21:35
阅读次数:
122
BOM:浏览器对象模型,可以使JS有能力操作浏览器 DOM:文档对象模型,可以访问HTML文档内的所有元素 Window对象 所有浏览器都支持 window 对象。它表示浏览器窗口 一些常用的Window方法: window.innerHeight 浏览器窗口的内部高度 window.innerWi ...
分类:
其他好文 时间:
2020-01-03 12:24:19
阅读次数:
73
问题简述: 使用servlet与vue-axios进行前后端交互时,设置好了跨域,其后因考虑到用户验证问题,在前端请求时加入了请求头如下 axios.defaults.headers.common['token'] = sessionStorage.getItem("token"); 其后,浏览器便 ...
分类:
移动开发 时间:
2020-01-02 22:42:20
阅读次数:
217
继续沿用第七天数据库:def test2(request): # 1.xxx__lt 小于 :查询出年龄小于22的所有 ret=models.Person.objects.filter(age__lt=22) print(ret) # 2.xxx__lte 小于等于 ret=models.Perso ...
分类:
编程语言 时间:
2020-01-01 20:30:56
阅读次数:
92
You are playing the following Flip Game with your friend: Given a string that contains only these two characters: + and -, you and your friend take tu ...
分类:
其他好文 时间:
2020-01-01 13:29:36
阅读次数:
62
allocator_type get_allocator() const noexcept; 返回和对象相关的分配器的一个拷贝 #include <iostream>#include <string>#include <vector>using namespace std;int main(){ v ...
分类:
其他好文 时间:
2019-12-31 18:52:14
阅读次数:
95
web.xml是tomcat和spring间的桥梁,是tomcat构建spring运行环境的说明书 It is a web application deployment descriptor file, contains detail description about web applicatio ...
分类:
编程语言 时间:
2019-12-31 18:41:47
阅读次数:
67
Executor Framework e.g. Runnable interface specifies a task to execute concurrently with other tasks. run() contains the task to perform. Executor Int ...
分类:
编程语言 时间:
2019-12-31 18:23:13
阅读次数:
66
不多说,上代码: 1 void C目录选择对话框Dlg::OnBnClickedButton1() 2 { 3 TCHAR szPath[MAX_PATH] = { 0 }; 4 BROWSEINFO mBroInfo = { 0 };/*Contains parameters for the SH ...
分类:
其他好文 时间:
2019-12-31 01:17:57
阅读次数:
90
Java判断一个字符串是否是包含某个字符 在java中我们经常要判断一个字符串是否被包含在另外一个字符集中,那么如何用代码实现这个功能需求呢? contains 方法 该方法返回true,如果此字符串包含,否则返回false。 indexof 方法 indexOf 的返回值为 int 如果找到,则返 ...
分类:
编程语言 时间:
2019-12-28 19:02:06
阅读次数:
229