java新手,刚自己敲了一代嘛,但是运行不了,没有错误提示额,求解各位大神。
public class ShuCha {int cha;
int jie(int x,int y){
cha=x-y;
return cha;
}
}
public class ShuHe {
int he;
int jia(int x,int y){
he=x+y;
return he;
}
}
public class YunShuang {
public static void main(){
int x1=9,y2=8;
ShuHe a=new ShuHe();
ShuCha b=new ShuCha();
int c,d;
c=a.jia(x1,y2);
d=b.jie(x1,y2);
System.out.println(c);
System.out.println(d);
}
}