Frage im Vorstellungsgespräch bei JPMorganChase

Questions about string and some simple greedy algorithm