Rosetta Problems

Irreversible operation

https://atcoder.jp/contests/agc029/tasks/agc029_a