Pergunta de entrevista da empresa KPIT Technologies

Coding question on strings in hacckerank