Rosetta Problems

FESTIVAL

https://atcoder.jp/contests/cf16-exhibition-final/tasks/cf16_exhibition_final_g