Domanda di colloquio di Groupon

Bit manipution & an algorithm question about string.