vexorian's blog

By vexorian, 15 years ago, In English
  • Vote: I like it
  • +13
  • Vote: I do not like it

15 years ago, hide # |
 
Vote: I like it +6 Vote: I do not like it
Someone please share how to solve problem E. thanks
15 years ago, hide # |
 
Vote: I like it +5 Vote: I do not like it
you use DFS to set direction of all edges and then find strongly conected componetnts
if there are more then one component - print 0
else - print edges