Rosetta Problems

最古の遺跡

https://atcoder.jp/contests/joi2007ho/tasks/joi2007ho_c