哦,原来与此,也可以这样调用。
int num = 10;
public static void main(String[] args) {
new Test6().new Inner1().show();
}
class Inner1 {
public int num = 20;
public void show() {
int num = 30;
System.out.println(num);
System.out.println(this.num);
System.out.println(Test6.this.num);
}
} |