Rosetta Problems

Making Rope from Materials

https://atcoder.jp/contests/awc0024/tasks/awc0024_e