algorithms.tutorialhorizon.com
Check if given an edge is a bridge in the graph | Algorithms
Given a graph and an edge, write a program to check if the edge is a bridge. Bridge in Graph: An edge is called a bridge if connects two subgraphs and removing the edge will disconnect the graph. Approach: Depth-First Search(DFS) Do the DFS to count the number of connected components (If the graph is fully connected then count would be 1).