一:对象实例化问题:
public class Rectangle {
public int width = 3;
public int height = 4;
public int area() {
return width * height;
}
}
则如下代码输出结果为:
Rectangle re...
一:多态问题class Father { public void hello() { System.out.println("Father says hello."); } } public class Child extends Father { int age=10; static int number=20; ...