求解超实用小程序??? 0 1 2 3 4 5 6 7 8 9 < > * + - 等15个字符随机输出4行21列 密码区!并且可以复制出来使用!用高手么??请留下QQ吧!谢谢 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 public class Test { //种子 static String[] seed = {"0","1","2","3","4","5","6","7","8","9","<",">","*","+","-"}; public static void main(String[] args) { //行数 int colnum = 4; //列数 int rownum = 21; for( int i=0;i<colnum;i++){ for(int j=0;j<rownum;j++){ System.out.print(seed[getIndex()] + " "); } System.out.println(); } } public static int getIndex(){ int rand = (int)(Math.random()*1000); return rand%15; }} 6 8 9 5 < 1 8 0 6 5 0 + 1 2 1 + < + 0 8 0 - 2 4 3 3 1 > 8 5 7 6 0 1 + 1 + + 5 7 2 4 7 < 1 - * 3 5 9 - - * < 6 0 7 0 4 4 4 * > 1 5 8 6 4 3 + * * 3 < * 8 > < * 2 + 8 4 5 java Socket聊天系统错误,求解啊,谢谢各位啦!!!!! for (;;)主要用在哪些方面? java帮我分析下 重新认识netbeans 如何建立自己定义的AudioStream? .class文件怎么打开? int 赋值问题.立即结 请问布局管理器高手 SCJP模拟题 about String Array 小弟是java初学者,烦各位高手相助,不胜感激!!! 有没有办法?在1.htm把2.htm框架的同时加上个一段代码语言,替换不要的代码呢, 新人求个程序
public class Test {
//种子
static String[] seed = {"0","1","2","3","4","5","6","7","8","9","<",">","*","+","-"};
public static void main(String[] args) {
//行数
int colnum = 4;
//列数
int rownum = 21;
for( int i=0;i<colnum;i++){
for(int j=0;j<rownum;j++){
System.out.print(seed[getIndex()] + " ");
}
System.out.println();
}
}
public static int getIndex(){
int rand = (int)(Math.random()*1000);
return rand%15;
}
}
6 8 9 5 < 1 8 0 6 5 0 + 1 2 1 + < + 0 8 0
- 2 4 3 3 1 > 8 5 7 6 0 1 + 1 + + 5 7 2 4
7 < 1 - * 3 5 9 - - * < 6 0 7 0 4 4 4 * >
1 5 8 6 4 3 + * * 3 < * 8 > < * 2 + 8 4 5