Pregunta de entrevista de Rakuten

One string manipulation question and one dp related problem