您的位置:首页 > 其它

问题

2015-08-30 23:20 197 查看
//下黑子的方法

public class PLay{

public static String[][] hz(String[][] a,int x,int y){

a [x][y]="●";

for (int m=0;m<25;m++){

for(int n=0;n<25;n++){

System.out.print(a[m]
);

}

System.out.println();

}

return a;

}

}

//调用

public class Main {

public static void main(String[] args) {

Play play=new Play();

String [][] num =new String[25][25];

for(int i=1;i<=625;i++){

if (i%2!=0){ // 判断黑子白子;

int x=play.Appointx(); // 这里调用一个x坐标的方法;

int y=play.Appointy(); // 这里调用一个Y坐标的方法;

num[25][25]=play.hz(num, x, y); //一直在提示我类型不匹配,表示不懂啊。

}

}

}

最后一行那个位置一直在提示我类型不匹配,表示不懂啊。都是定义的二维数组类型,为什么eclipse里提示我说不能从String[][]转换为String?

最后一行那个位置一直在提示我类型不匹配,表示不懂啊。都是定义的二维数组类型,为什么eclipse里提示我说不能从String[][]转换为String?

最后一行那个位置一直在提示我类型不匹配,表示不懂啊。都是定义的二维数组类型,为什么eclipse里提示我说不能从String[][]转换为String?
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: