package Z; public abstract class A { private String name; public A(String name) { this.name=name; } public String getName() { return this.name; } public abstract void fun(); }
package Z; public abstract class A { private String name; public A(String name) { this.name=name; } public String getName() { return this.name; } public abstract void fun(); }
package Z; public class DemoAB { public static void main(String[] args) { B b =new B("XIAOAI"); b.fun(); } }