Topic: help(“非法的类型开始” “需要〈标识符〉”)

  Print this page

1.help(“非法的类型开始” “需要〈标识符〉”) Copy to clipboard
Posted by: xingchao
Posted on: 2006-10-13 21:41

帮帮忙 这个错在那里了?
为什么在编译时 告送我 “非法的类型开始” “需要〈标识符〉”??

import java.io.*;
class Input{
static String s="";
static void input(){
BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
try{
s=br.readLine();
}catch(IOException e){}
}
static public int getInt(){
input();
return Integer.parseInt(s);
}
}
class CMatrix{
int a[][]=new int[4][5];
int row=0,col=0;
int max = a[0][0];
for(int i=0;i<a.length;i++){
for(int j=0;j<a[0].length;j++)

a[i][j]=Input.getInt();
System.out.print(a[i][j]+"\t");
System.out.print("\n");

}
void find(){
for(int i=0;i<a.length;i++){
for(int j=0;j<a[0].length;j++)

if(a[i][j]>max) {
max=a[i][j];
row=i;
col=j;
}
}

System.out.println("the max :"+max);
System.out.println("row="+row);
System.out.println("col="+col);
}

}
public class Matrix{
public static void main(String[] args){
CMatrix c=new CMatirx();
c.find();

}
}


   Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent
Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1
客服电话 18559299278    客服信箱 714923@qq.com    客服QQ 714923