重新做了一下这道并查集的题目,关键要点是抓住这种循环的关系和模运算的通性,进而利用加权并查集 #include <cstdio> #include <iostream> #include <algorithm> #include <cstring> using namespace std; cons ...
分类:
其他好文 时间:
2020-07-15 23:39:09
阅读次数:
63
1、dubbo:com.alibaba.dubbo.rpc.RpcException: Failed to invoke the method问题 根据报错内容, 可能的解决方法有: 1.1 传输类没有序列化,dubbo中接口的返回类必须序列化,不序列化不能进行网络传输 1.2 设置dubbo超时时 ...
分类:
其他好文 时间:
2020-07-15 15:15:47
阅读次数:
57
hadoop Shuffle Error: Exceeded MAX_FAILED_UNIQUE_FETCHES; bailing-out 程序里面打开文件数达到上限,系统一般默认数量是1024,(用ulimit -a可以看到)vi /etc/security/limits.conf 添加 :sof ...
分类:
其他好文 时间:
2020-07-15 12:46:25
阅读次数:
86
Given an array of integers and an integer k, you need to find the number of unique k-diff pairs in the array. Here a k-diff pair is defined as an inte ...
分类:
其他好文 时间:
2020-07-15 01:00:03
阅读次数:
73
1、find 用于查找文件或者目录 find path options [commad] 【options】: -size 按文件大小查找 -empty 查找空白文件或目录 -name 按文件名称查找 -iname 按文件名称查找,不区分大小写 -user 按文件属性主查找 -group 按文件属组 ...
分类:
系统相关 时间:
2020-07-14 21:54:07
阅读次数:
103
echo "export LC_ALL=en_US.UTF-8" >> /etc/profile source /etc/profile原因是因为没有配置正确的语言环境造成的 ...
分类:
其他好文 时间:
2020-07-14 18:20:49
阅读次数:
159
//线程池创建,线程池提交任务使用Callable int corePoolSize = 3; int maximumPoolSize = Runtime.getRuntime().availableProcessors() * 2; BlockingQueue<Runnable> queue = ...
分类:
编程语言 时间:
2020-07-14 16:20:51
阅读次数:
63
在RedHat下有时候用rpm安装软件是会出现下面则中错误 1、安装时提示:warning: *.rpm: Header V3 RSA/SHA256 Signature, keykey ID c105b9de: NOKEY 解决的方法就是在rpm 语句后面加上 --force --nodeps 即原 ...
分类:
其他好文 时间:
2020-07-14 13:31:45
阅读次数:
95
监控工具:jvisualVM、VisaulVM、jprofiler JVM优化书籍:《Java性能优化权威指南》、《深入理解java虚拟机》 1.年轻代空间不足 2.per Gen(永久代)空间满 3.CMS GC时出现promotion failed和concurrent mode failure ...
分类:
其他好文 时间:
2020-07-14 10:36:50
阅读次数:
187
给定一个范围在 1 ≤ a[i] ≤ n ( n = 数组大小 ) 的 整型数组,数组中的元素一些出现了两次,另一些只出现一次。 找到所有在 [1, n] 范围之间没有出现在数组中的数字。 您能在不使用额外空间且时间复杂度为O(n)的情况下完成这个任务吗? 你可以假定返回的数组不算在额外空间内。 示 ...
分类:
编程语言 时间:
2020-07-14 00:33:56
阅读次数:
60