两个小示例
demo1
package containers; public class TempTest { static{ a= 1; // System.out.println(a); } static int a= 0; public static void main(String[] args) { Utilities.println(a); } }
demo2
package containers; public class TempTest2 { static int a = 1; static { a = 0; } public static void main(String[] args) { Utilities.println(Integer.valueOf(a)); } }
参考反编译文件
你的能量超乎你想象_________