Rosetta Problems

Baumkuchen

https://onlinejudge.u-aizu.ac.jp/problems/0600