Pregunta de entrevista de AccioJob

Next higher permutation. Longets common subsequence