两天没更新的我又回来了
int[] arrays={1,9,23,96,240,0,36}; Arrays.sort(arrays); for(int a:arrays){ System.out.println(a); }
输出结果为:
0 1 9 23 36 96 240
int[] arrays={1,9,23,96,240,0,36}; Arrays.fill(arrays,0); for(int a:arrays){ System.out.println(a); }
输出结果为:
0 0 0 0 0 0 0
int[] a={1,2,3}; int[] b={1,2,3}; System.out.println(Arrays.equals(a,b));
输出结果为:
true
int[] arrays={1,9,23,96,240,0,36}; System.out.println(Arrays.binarySearch(arrays,9));
输出结果为:
1