Rosetta Problems

Avoid Rook Attack

https://atcoder.jp/contests/abc377/tasks/abc377_b