From 314fdba6e300d8976835d6883540996e03e96e60 Mon Sep 17 00:00:00 2001 From: Yidi Date: Tue, 28 Jan 2025 15:22:57 +0100 Subject: fix test --- test/graph/euler.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'test/graph/euler.cpp') diff --git a/test/graph/euler.cpp b/test/graph/euler.cpp index 6666040..457ca99 100644 --- a/test/graph/euler.cpp +++ b/test/graph/euler.cpp @@ -1,6 +1,6 @@ #include "../util.h" struct Euler { - Euler(int n) : idx(n), validIdx(n) {} + Euler(int n) : adj(n) {} #include }; @@ -20,7 +20,7 @@ Euler eulerGraph(int n, int m) { } int last = -1; for (int i = 0; i < n; i++) { - if (sz(res.idx[i]) % 2 != 0) { + if (sz(res.adj[i]) % 2 != 0) { if (last >= 0) { res.addEdge(last, i); last = -1; @@ -44,8 +44,8 @@ void stress_test() { vector> expected(n); for (int i = 0; i < n; i++) { - for (int j : g.idx[i]) { - expected[i].push_back(g.to[j]); + for (auto [j, rev] : g.adj[i]) { + expected[i].push_back(j); } sort(all(expected[i])); } -- cgit v1.2.3