|
发表于 2020-6-10 14:30:01
|
显示全部楼层
我刚写了,你看看,行不行
class Test
{
public static void main(String[] args)
{
String[] strAr= {"1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","J","K","L","M","N","P","Q","R","S","T","U","V","W","X","Y","Z"};
String num = "0000";
String ge="";
String shi="";
String bai="";
String qian="";
int s=0;
int genum=0,shinum=0,bai=0,qian=0;
int length=strAr.length();
while(true){
s++;
genum++;
if(genum<length){
num=num.subString(1,3)+geunm.toString;
}else{
genum=0;
shinum++;
if(shinum<length){
num=num.subString(1,2)+shinum.toString+"0";
}else{
shinum=0;
bainum++;
if(shinum<length){
num=num.subString(1,1)+bainum.toString+"00";
}else{
bainum=0;
qiannum++;
if(qiannum<length){
num=qiannum.toString+"000";
}else{
break;
}
}
}
}
System.out.println(s+":"+gennum);
}
}
} |
|