Rosetta Problems

Tree weight

https://marisaoj.com/problem/200