String str = "123456";
char[] arr1 = str.toCharArray();
char[] arr2 = Arrays.copyOf(arr1,arr1.length);
for(int i=0;i<arr1.length-1;i++){
for(int j = i+1;j<arr2.length;j++){
System.out.println(arr1[i] + "," + arr2[j]);
}
}
123456所有排列组合
最新推荐文章于 2021-05-20 12:49:47 发布