62,628
社区成员
发帖
与我相关
我的任务
分享
public static void main(String[] args) {
Random r = new Random();
int[] str = new int[100000000];
for (int i = 0; i < num; i++) {
str[i] = (r.nextInt() >>> 1) % 100000000;
}
sortStr(str);
}
Error occurred during initialization of VM
Could not reserve enough space for object heap
public static void main(String[] args) {
Random r = new Random();
int[] str = new int[100000000];
for (int i = 0; i < 100000000; i++) {
str[i] = (r.nextInt() >>> 1) % 100000000;
}
// sortStr(str);
}