public static void main(String[] args){
Random d = new Random();
String str = "";
for(int i=0;i<4;i++){
int num = d.nextInt(10);
str += num+"";
}
System.out.println(str);
}
时间: 2024-10-12 20:47:49
public static void main(String[] args){
Random d = new Random();
String str = "";
for(int i=0;i<4;i++){
int num = d.nextInt(10);
str += num+"";
}
System.out.println(str);
}