Finding a cycle in an undirected graph

Posted by Evilsithgirl on Stack Overflow See other posts from Stack Overflow or by Evilsithgirl
Published on 2010-03-18T02:33:56Z Indexed on 2010/03/18 2:41 UTC
Read the original article Hit count: 392

Filed under:
|
|

I need write an algortihm to find a cycle in an undirected graph using O(|V|) time independent of O(|E|). So a running time of O(|V| + |E|) won't be accepted. how can i do this? Will Depth-first search work?

© Stack Overflow or respective owner

Related posts about algorithm

Related posts about graph