Rosetta Problems

Colorful Stone Sorting

https://atcoder.jp/contests/ttpc2024_2/tasks/ttpc2024_2_m