Concept Flow - Cycle Detection in Undirected Graph
Start at any node
Mark node as visited
For each neighbor
If neighbor not visited
Recurse DFS
Detect cycle
End
Start DFS from any node, mark visited, explore neighbors. If a visited neighbor is not the parent, a cycle exists.
