Pergunta de entrevista da empresa IBM

Technical question is pretty basic.