In - time for node
t_in [ node ] = T ; for ( let i = 0 ; i < g [ node ] . length ; i ++ ) { if ( g [ node ] [ i ] != parent ) { T ++ ; dfs ( g [ node ] [ i ] , node , g , level , t_in , t_out ) ; } } T ++ ;