标题: 求解答 [打印本页] 作者: 学不死往死学 时间: 2015-10-13 21:40 标题: 求解答 class Hello {
public static void main(String[] args) {
Zi a = new Zi();
a.print();
System.out.println();
}
}
class Fu {
int age = 20;
public void print(){
System.out.println("fu"+age);
}
}
class Zi extends Fu{
public void print(){
super.print();
this.age = 10 ;
super.print();
System.out.println("zi"+this.age);
}
}
结果有点晕.求大神解答 作者: liuzhiyong 时间: 2015-10-13 22:06
class Zi extends Fu{
public void print(){