Rosetta Problems

Beautiful String

https://atcoder.jp/contests/agc066/tasks/agc066_f