package Zero; class A{ int i; public static A getInstance(){ A a=new A(); a.i=2; return a; } } class Execute11 { public static void main(String[] args){ A a1=new A(); a1.i=1; a1=A.getInstance(); System.out.println(a1.i); } } 我每次都搞不清楚是输出该1,还是2,还望高手指点