Rosetta Problems

ビリヤード (Billiards)

https://atcoder.jp/contests/joi2025yo2/tasks/joi2025_yo2_b