Pregunta de entrevista de Barclays

String palindrome and permutation formula and generation