Rosetta Problems

From Station to Station

https://atcoder.jp/contests/awc0034/tasks/awc0034_b