summaryrefslogtreecommitdiff
path: root/content/graph/connect.cpp
diff options
context:
space:
mode:
authorMZuenni <michi.zuendorf@gmail.com>2024-08-01 17:57:07 +0200
committerMZuenni <michi.zuendorf@gmail.com>2024-08-01 17:57:07 +0200
commit231a5826865f712e08f499c92594024728fd785d (patch)
tree848a55bcd0bd157efa626614c5747c80abcb3c45 /content/graph/connect.cpp
parentd7905f7dec9e306d7d6f907ce35abc40f24af1c5 (diff)
new tests
Diffstat (limited to 'content/graph/connect.cpp')
-rw-r--r--content/graph/connect.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/content/graph/connect.cpp b/content/graph/connect.cpp
index ffcd6c2..7940b37 100644
--- a/content/graph/connect.cpp
+++ b/content/graph/connect.cpp
@@ -10,7 +10,7 @@ struct connect {
}
void addEdge(int u, int v, int id) {
- lct.nodes[id + n] = LCT::Node(id + n, id + n);
+ lct.nodes[id + n] = LCT::Node(id + n, id);
edges[id] = {u, v};
if (connected(u, v)) {
int old = lct.query(&lct.nodes[u], &lct.nodes[v]);