procon_lib_rs

This documentation is automatically generated by online-judge-tools/verification-helper

View the Project on GitHub CoCo-Japan-pan/procon_lib_rs

:warning: verify/yosupo/strongly_connected_components/src/main.rs

Depends on

Code

// https://judge.yosupo.jp/problem/scc

use proconio::{fastout, input};
use scc::SccGraph;

#[fastout]
fn main() {
    input! {
        n: usize,
        m: usize,
        a_b: [(usize, usize); m],
    }
    let scc_graph = {
        let mut scc_graph = SccGraph::new(n);
        for (a, b) in a_b {
            scc_graph.add_edge(a, b);
        }
        scc_graph
    };
    let scc = scc_graph.scc();
    println!("{}", scc.len());
    for scc in scc {
        print!("{}", scc.len());
        for &v in scc.iter() {
            print!(" {}", v);
        }
        println!();
    }
}
Traceback (most recent call last):
  File "/opt/hostedtoolcache/Python/3.13.9/x64/lib/python3.13/site-packages/onlinejudge_verify/documentation/build.py", line 71, in _render_source_code_stat
    bundled_code = language.bundle(stat.path, basedir=basedir, options={'include_paths': [basedir]}).decode()
                   ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/hostedtoolcache/Python/3.13.9/x64/lib/python3.13/site-packages/onlinejudge_verify/languages/rust.py", line 288, in bundle
    raise NotImplementedError
NotImplementedError
Back to top page