// Collection of code snippets by Arne Vajhøj 
// (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) 
public class ThisFun1 {
    public static void main(String[] args) {
        A a = new A();
        A.B b = a.new B();
        A.B.C c = b.new C();
        c.demo();
    }
}

class A {
    public void dump() {
        System.out.println("I am A");
    }
    class B {
        public void dump() {
            System.out.println("I am B");
        }
        class C {
            public void dump() {
                System.out.println("I am C");
            }
            public void demo() {
                dump();
                this.dump();
                C.this.dump();
                B.this.dump();
                A.this.dump();
            }
        }
    }
}
