Pregunta de entrevista de Tech extensor

They were asked Problem solving logic to me.