Feb. 21, 2014, 4:23 p.m. by Rosalind Team
Topics: Graphs
The task is to use depth-first search to compute the number of connected components in a given undirected graph.
Given: A simple graph with
Return: The number of connected components in the graph.
See Figure 1 for visual example from the sample dataset.
12 13 1 2 1 5 5 9 5 10 9 10 3 4 3 7 3 8 4 8 7 11 8 11 11 12 8 12
3