Goldman Sachs interview question

Some string manipulation, implementing hashmap.