public class testing {
static testing tmp = new testing();
testing() {
System.out.println("You are good");
}
public static void main(String... str) {
}
}
In the above code 'You are good' is printed. But I want to know why this happened as constructor is non static method and static variables execute before not static methods.