Rosetta Problems

Place Signposts to Guide the Way

https://atcoder.jp/contests/awc0168/tasks/awc0168_d