Black_hat123's blog

By Black_hat123, history, 5 years ago, In English

Can someone please help in This problem.

  • Vote: I like it
  • 0
  • Vote: I do not like it

| Write comment?
»
5 years ago, # |
  Vote: I like it 0 Vote: I do not like it

For each node you can precompute jumps with lengths powers of 2 and answer queries using binary lifting.

»
5 years ago, # |
  Vote: I like it 0 Vote: I do not like it