TARJAN: articulation point and bridges for undirected (and directed) graphs.