XNight_KingX's blog

By XNight_KingX, history, 3 months ago, In English,

which one is better for bipartition check BFS or DFS? I think DFS is better but not able to Deduce this intuition clearly? can you help me with that. Noobie here, pls go less hard>> :)

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

»
3 months ago, # |
  Vote: I like it 0 Vote: I do not like it

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

»
3 months ago, # |
  Vote: I like it 0 Vote: I do not like it

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

»
3 months ago, # |
  Vote: I like it 0 Vote: I do not like it

No, it's your output -1, but jury says it is bipartite

»
3 months ago, # |
  Vote: I like it 0 Vote: I do not like it

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

»
3 months ago, # |
  Vote: I like it +8 Vote: I do not like it

which one is better for bipartition check BFS or DFS? I think DFS is better but not able to Deduce this intuition clearly? can you help me with that. Noobie here, pls go less hard>> :)

In general there is no difference, use what is comfortable to implement.