Rosetta Problems

The Last Ant

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