class A { public static void print() { } } class B extends A { public static void print() { } } class C { B b = new A(); b.print(); } }
Standard input is empty
Main.java:15: error: incompatible types: A cannot be converted to B B b = new A(); ^ 1 error
Standard output is empty