随机输出验证码

 1 String a = new String("0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ");
 2         
 3         System.out.print("请输入验证码:");
 4         
 5         for (int b=0; b<=5; b++)
 6         {
 7             Random rn = new Random();
 8             
 9             int c = rn.nextInt(62);
10             
11             System.out.print(a.charAt(c) + " ");
12         }
View Code
原文地址:https://www.cnblogs.com/zxw0004/p/4874460.html