package Test02;
public class test8 {
static int i = 47;//定义一个静态成员变量
public void method1() {//定义一个成员方法
System.out.println("method1被调用");
for(i = 0;i<3;i++) {
System.out.print(i+" ");
}
System.out.println();
}
public test8() {//定义一个构造方法
}
public static void main(String[] args) {
test8 t1 = new test8();//定义对象t1
test8 t2 = new test8();//定义对象t2
t2.i=60;
System.out.println("t1调用静态成员变量i的结果:"+t1.i++);
t1.method1();
System.out.println("t2调用静态成员变量i的结果:"+t2.i);
t2.method1();
}
}

你的method1不是又赋值成0了吗?最终返回2,在你的 System.out.println("t1调用静态成员变量i的结果:"+t1.i++); 有加了1,结果就是3了
for(i = 0;i<3;i++) {
System.out.print(i+" ");
}
换成下面这个
for(;i<3;i++) {
System.out.print(i+" ");
}