Google interview question

String Manipulation through recursion.