Rosetta Problems

有理数树

https://www.acwing.com/problem/content/701