Pregunta de entrevista de Tibra

Some coding, and a similar triangle problem