MathWorks interview question

Java, OOPS concepts.