Pregunta de entrevista de IBM

Basics in Java and some from python