Pregunta de entrevista de Dayforce

Leetcode Two Sum solve it.