GoTo interview question

Simple programming on String Manipulation & Array