Pergunta de entrevista da empresa Art & Logic

2 part coding question, followed by an essay section.