Google interview question

String operation on an integer array