Adobe interview question

Hackerrank problems with string manipulation