Omar_Mekkawy's blog

By Omar_Mekkawy, history, 4 years ago, In English,

Regarding finding articulation points, we use dfs order (dfs time) , to know the exact time of visiting this node, taking the maximum time of my children to assign if i'm articulation , and the minimum is returned to my parent,

i tried to switch the dfs order to using depth , meaning that the dfs order of the node is it's depth and i take the maximum depth for myself and return the minimum depth to my parent, but it hasn't been working i've been getting wrong answers,

Should it work or not, and if not could you provide the test case?

 
 
 
 
  • Vote: I like it
  • +8
  • Vote: I do not like it

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

Auto comment: topic has been updated by Omar_Mekkawy (previous revision, new revision, compare).

»
4 years ago, # |
Rev. 2   Vote: I like it +3 Vote: I do not like it

Could you link the problem and your code? The depth change looks fine to me, i changed my code to your approach on a UVA problem and it also gets AC