An algorithm for the blocks and cutnodes of a graph | Synapse