***Edit: should be a2 = new B()***
I don't understand why the result for a2.foo(b) is 3 in the following practice question.

I thought with polymorphism, the dynamic types method would run with the method signature that takes the argument that corresponds with the static type. 

```
public class A {
    public int foo(Object o) {
        System.out.println(1);
        return 1;
    }

    public int foo(A a) {
        System.out.println(2);
        return 2;
    }
}

public class B extends A {
    public int foo(A a) {
        System.out.println(3);
        return 3;
    }

    public int foo(B b) {
        System.out.println(4);
        return 4;
    }

public static void main(String[] args) {
        A a2 = new B();
        B b = new B();
        a2.foo(b);
    }
}

```

The answer my school has given is a2.foo(b) returns 3, however I thought it would return 4.

Thanks in advance!