Блог пользователя ubercool

Автор ubercool, история, 5 лет назад, По-английски

Can anyone explain how we are taking the subtree in this problem??Link

Полный текст и комментарии »

  • Проголосовать: нравится
  • 0
  • Проголосовать: не нравится

Автор ubercool, история, 5 лет назад, По-английски

I was solving QTREE2 on SPOJ but I am getting WA I can't find my mistake can anyone point it out pls.Here is my code.

Полный текст и комментарии »

  • Проголосовать: нравится
  • 0
  • Проголосовать: не нравится

Автор ubercool, история, 5 лет назад, По-английски

I was solving tourists problem on kattis and keep on getting WA ,I can't understand what I am doing wrong.Here is a link to my code.The problem is asking for the sum of all paths between such vertex pair (x,y) where y>x and y%x is zero.

Полный текст и комментарии »

  • Проголосовать: нравится
  • 0
  • Проголосовать: не нравится

Автор ubercool, история, 5 лет назад, По-английски

I was solving tourists problem on kattis and keep on getting WA ,I can't understand what I am doing wrong.Here is a link to my code.The problem is asking for the sum of all paths between such vertex pair (x,y) where y>x and y%x is zero.

Полный текст и комментарии »

  • Проголосовать: нравится
  • -6
  • Проголосовать: не нравится

Автор ubercool, история, 5 лет назад, По-английски

I am solving the problem QTREE2 on Spoj.[](http://www.spoj.com/problems/QTREE2/) I am learning LCA and I have calculated LCA using euler tour.But I am unable to find the answer to the second type of query which asks about Kth node in a path from node a to node b in a tree.How do we solve it ??

Полный текст и комментарии »

  • Проголосовать: нравится
  • 0
  • Проголосовать: не нравится