Finally keyword2978 - Java Quiz Question


What will be the output of the following program?

public class FinallyDemo {
    class Manhattan {
        void doStuff() {
            System.out.println("X ");
        }
    }
    class TimesSquares extends Manhattan {
        @Override
        void doStuff() {
        }
    }
    public static void main(String[] args) {
        new FinallyDemo().go();
    }
    void go() {
        new TimesSquares().doStuff();
    }
}


A
X
B
X X
C
(No output)
D
Compilation Error
E
Runtime Error