208 E Problem Help

Правка en1, от retr0coderxyz, 2020-03-19 14:39:51

Can anyone tell me how to solve this problem: 208E.

I saw few solutions and I understood till the LCA part I dont understand why should we renumber the tree and why is binary search used here. It would be great if anybody could help me out with this. Please and thank you so much :)

Теги #binary-lifting, lca

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en1 Английский retr0coderxyz 2020-03-19 14:39:51 303 Initial revision (published)