pub fn is_cycle<Graph: StaticGraph>(graph: &Graph) -> bool
Returns true if the given graph is a cycle.