fn loops(n: usize, edges: &[Vec<usize>]) -> Vec<Vec<usize>>
Strongly connected components with more than one task (Tarjan 1972): the loops.