Pregunta de entrevista de IBM iX

Some basic Java OO related question and a simple algorithm question