思路:在建树的同时进行判断,把建树的模板改一改就能用 #include<iostream> #include<queue> #include<string.h> #include<string> #include<map> #include<unordered_map> #include<vecto ...
分类:
其他好文 时间:
2021-02-17 14:00:40
阅读次数:
0
【推荐】集合初始化时,指定集合初始值大小。 说明:HashMap 使用 HashMap(int initialCapacity) 初始化, 正例:initialCapacity = (需要存储的元素个数 / 负载因子) + 1。注意负载因子(即 loader factor)默认为 0.75,如果暂时 ...
分类:
其他好文 时间:
2021-02-16 12:43:16
阅读次数:
0
hashMap的四种遍历方式 使用entrySet返回包含entry的Set集合再遍历 Map<String,String> map=new HashMap<>(); map.put("1","stu01"); map.put("2","stu02"); Set<Entry<String,Strin ...
分类:
其他好文 时间:
2021-02-16 12:33:39
阅读次数:
0
for in 和for of的区别:https://www.cnblogs.com/zjx304/p/10687017.html 1 遍历数组通常用for循环 ES5的话也可以使用forEach,ES5具有遍历数组功能的还有map、filter、some、every、reduce、reduceRig ...
分类:
其他好文 时间:
2021-02-16 12:23:46
阅读次数:
0
SpringSecurity的身份认证流程、SpringSecurity做JWT身份认证流程和请求的认证流程 ...
分类:
编程语言 时间:
2021-02-16 11:54:35
阅读次数:
0
虽然不经常使用Hashtable,但是会经常使用Properties。 Properties是Hashtable的子类,是线程安全的。 Properties的key和value都是String类型的,又称为属性对象。 特点是key无序、不可重复。 其中有几个常用的方法: Object setProp ...
分类:
其他好文 时间:
2021-02-15 11:55:52
阅读次数:
0
#include<bits/stdc++.h> using namespace std; const int maxn=1e5+100; const int inf=1e9; int n,m,x; int dep[maxn];//节点在第几层 int num[maxn];//每一层的节点个数 int ...
分类:
其他好文 时间:
2021-02-15 11:49:10
阅读次数:
0
Oracle表连接方法有四种: 排序合并连接(Sort Merge Join) 嵌套循环连接(Nested Loops Join) 哈希连接(Hash Join) 笛卡尔积(Cartesian Product) 排序合并连接(Sort Merge Join) 排序合并连接是将连接的两个表使用连接列排 ...
分类:
其他好文 时间:
2021-02-09 12:42:10
阅读次数:
0
在围绕Hadoop形成的大数据技术生态当中,MapReduce的地位,在早期是处于核心地位的,但是伴随着数据处理实时性需求的不断提升,更多新的计算框架出现,MapReduce的地位受到压制,但是作为Hadoop原始计算框架,还是需要相应程度的了解和掌握的。今天的大数据入门分享,我们来具体讲一讲Map ...
分类:
其他好文 时间:
2021-02-09 12:33:28
阅读次数:
0
问题引入 有一个长为 \(N\) 的数组 \(k\) 与一个长为 \(M\) 的数组 \(d\),求出 \(d\) 数组中能被 \(\le 2\) 个 \(k\) 数组中的数相加表示出来的数有多少个。 本题多组数据。 \(1\le N,M,k_i,d_i\le 2\times 10^5\)。 原题链 ...
分类:
其他好文 时间:
2021-02-09 12:19:29
阅读次数:
0