Pergunta de entrevista da empresa Meta

Some string manipulations with hash maps, and big O complexity