File tree Expand file tree Collapse file tree 3 files changed +6
-6
lines changed
library/graphs/bridges_cuts
tests/library_checker_aizu_tests/graphs Expand file tree Collapse file tree 3 files changed +6
-6
lines changed Original file line number Diff line number Diff line change 5050"tests/library_checker_aizu_tests/flow/dinic_aizu.test.cpp" : " 2024-11-17 14:04:03 -0600" ,
5151"tests/library_checker_aizu_tests/flow/hungarian.test.cpp" : " 2024-11-17 14:04:03 -0600" ,
5252"tests/library_checker_aizu_tests/flow/min_cost_max_flow.test.cpp" : " 2024-12-05 10:41:42 -0600" ,
53+ "tests/library_checker_aizu_tests/graphs/bcc_callback.test.cpp" : " 2025-06-23 18:30:19 -0600" ,
5354"tests/library_checker_aizu_tests/graphs/biconnected_components.test.cpp" : " 2025-02-10 23:30:47 -0700" ,
5455"tests/library_checker_aizu_tests/graphs/connected_components_of_complement_graph.test.cpp" : " 2024-12-14 19:50:29 -0600" ,
55- "tests/library_checker_aizu_tests/graphs/cuts_callback.test.cpp" : " 2025-06-23 18:27:40 -0600" ,
5656"tests/library_checker_aizu_tests/graphs/dijkstra_aizu.test.cpp" : " 2024-12-14 19:50:29 -0600" ,
5757"tests/library_checker_aizu_tests/graphs/dijkstra_lib_checker.test.cpp" : " 2024-12-14 19:50:29 -0600" ,
5858"tests/library_checker_aizu_tests/graphs/directed_cycle.test.cpp" : " 2025-02-10 23:30:47 -0700" ,
Original file line number Diff line number Diff line change 55// ! vector<vector<int>> adj(n);
66// ! vector<pii> edges(m);
77// ! UF uf(n);
8- // ! cuts_callback (adj, [&](const vi& nodes) {
8+ // ! bcc_callback (adj, [&](const vi& nodes) {
99// ! if (sz(nodes) > 2)
1010// ! for (int v : nodes) uf.join(v, nodes[0]);
1111// ! });
2121// ! vector<basic_string<int>> adj(n);
2222// ! vector<basic_string<array<int, 2>>> adj_edge_ids(n);
2323// ! vector<bool> seen(m);
24- // ! cuts_callback (adj, [&](const vi& nodes) {
24+ // ! bcc_callback (adj, [&](const vi& nodes) {
2525// ! rep (i, 0, sz(nodes) - 1)
2626// ! for (auto [u, e_id] : adj_edge_ids[nodes[i]])
2727// ! if (!seen[e_id]) {
3333// ! callback not called on components with a single node
3434// ! @time O(n + m)
3535// ! @space O(n + m)
36- void cuts_callback (const auto & adj, auto f) {
36+ void bcc_callback (const auto & adj, auto f) {
3737 int n = sz (adj), q = 0 , s = 0 ;
3838 vi tin (n), st (n);
3939 auto dfs = [&](auto && self, int v) -> int {
Original file line number Diff line number Diff line change 11#define PROBLEM \
22 " https://judge.yosupo.jp/problem/biconnected_components"
33#include " ../template.hpp"
4- #include " ../../../library/graphs/bridges_cuts/cuts_callback .hpp"
4+ #include " ../../../library/graphs/bridges_cuts/bcc_callback .hpp"
55int main () {
66 cin.tie (0 )->sync_with_stdio (0 );
77 int n, m;
@@ -16,7 +16,7 @@ int main() {
1616 }
1717 vector<bool > vis (n, 0 );
1818 vector<vector<int >> all_bccs;
19- cuts_callback (adj, [&](const vi& nodes_bcc) {
19+ bcc_callback (adj, [&](const vi& nodes_bcc) {
2020 assert (ssize (nodes_bcc) >= 2 );
2121 for (int v : nodes_bcc) vis[v] = 1 ;
2222 all_bccs.push_back (nodes_bcc);
You can’t perform that action at this time.
0 commit comments