Google interview question

a question about string manipulation