Domanda di colloquio di MacroHealth

easy to medium leet code question. One was solved using two pointers and other one using hashing.