class A {
static {
System.out.println("A-SIB");
}
static void test(){
System.out.println("A-test");
}
}
class B extends A {
static {
System.out.println("B-SIB");
}
}
class C {
public static void main(String args []){
B.test();
}
}
Когда я запускал класс C, я думал, что A-SIB, B-SIB и A-test будут напечатаны, но B-SIB не было на выходе. Может кто-нибудь объяснить, почему?