Codeforces and Polygon may be unavailable from May 23, 4:00 (UTC) to May 23, 8:00 (UTC) due to technical maintenance. ×
Rating changes for last rounds are temporarily rolled back. They will be returned soon. ×

Heavy Light Decomposition Implementation

Revision en1, by dx24816, 2018-08-30 04:01:12

Hello,

I was trying to do the USACO problem Grass Planting (http://www.usaco.org/index.php?page=viewproblem2&cpid=102), but couldn't get my Heavy Light Decomposition to work. Can somebody direct me to a Heavy Light Decomposition implementation without LCA? Also, could someone also show me how to implement Heavy Light Decomposition with both the values on vertices and then with the values on the edges? I tried using Al.Cash's implementation, but for some reason, it failed. Thanks!

-dx24816

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English dx24816 2018-08-30 17:21:11 419
en1 English dx24816 2018-08-30 04:01:12 539 Initial revision (published)