package chapter18;

class Foo {
    int x = 0; // instance variable
    int y = 0;

    public static void main(String[] args) {
        Foo f = new Foo();
        f.p();
        System.out.println("After calling p() method");
        System.out.println("f.x = " + f.x);
        System.out.println("f.y = " + f.y);
    }

    void p() {
        int x = 1; // local variable
        System.out.println("Inside of p() method");
        System.out.println("x = " + x);
        System.out.println("y = " + y);
    }
}

