Pregunta de entrevista de Miro

DS questions. Time complexity, Space complexity.