Pregunta de entrevista de C3 AI

Leetcode medium/hard, plus some behaviorals.