Rosetta Problems

Dance Synchronization

https://atcoder.jp/contests/awc0086/tasks/awc0086_e