This DP On Trees question is easy to understand, but I was unable to find the solution after a couple of hours of trying. I read the editorial, but its a little confusing for me. Any hints or a more verbose explanation?
Thanks!
This DP On Trees question is easy to understand, but I was unable to find the solution after a couple of hours of trying. I read the editorial, but its a little confusing for me. Any hints or a more verbose explanation?
Thanks!