This documentation is automatically generated by competitive-verifier/competitive-verifier
// competitive-verifier: PROBLEM https://judge.yosupo.jp/problem/general_matching
#include <bits/stdc++.h>
#include "../graph/flow/gabow-edmonds.hpp"
using namespace std;
#ifdef LOCAL
#include "copypaste/debug.h"
#else
#define debug(...) 42
#endif
#define endl '\n'
struct fast_ios {
fast_ios() {
cin.tie(nullptr);
ios::sync_with_stdio(false);
cout << fixed << setprecision(10);
};
} fast_ios_;
int main() {
#ifdef LOCAL
freopen("./data.in", "r", stdin);
#endif
int N, M;
cin >> N >> M;
GabowEdmonds flow(N);
for (int i = 0; i < M; i++) {
int a, b;
cin >> a >> b;
flow.add_edge(a, b);
}
auto ret = flow.max_matching();
cout << ret.size() << endl;
for (auto &p : ret) cout << p.first << ' ' << p.second << endl;
}
Traceback (most recent call last):
File "/home/runner/.local/lib/python3.12/site-packages/competitive_verifier/oj_resolve/resolver.py", line 181, in resolve
bundled_code = language.bundle(path, basedir=basedir)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/runner/.local/lib/python3.12/site-packages/competitive_verifier/oj/verify/languages/cplusplus.py", line 252, in bundle
bundler.update(path)
File "/home/runner/.local/lib/python3.12/site-packages/competitive_verifier/oj/verify/languages/cplusplus_bundle.py", line 477, in update
raise BundleErrorAt(
competitive_verifier.oj.verify.languages.cplusplus_bundle.BundleErrorAt: test/yosupo-general-matching.test.cpp: line 9: unable to process #include in #if / #ifdef / #ifndef other than include guards
Env | Name | Status | Elapsed | Memory |
---|---|---|---|---|
g++ | example_00 |
![]() |
6 ms | 4 MB |
g++ | example_01 |
![]() |
5 ms | 4 MB |
g++ | issue610_00 |
![]() |
5 ms | 4 MB |
g++ | max_random_00 |
![]() |
8 ms | 4 MB |
g++ | max_random_01 |
![]() |
15 ms | 6 MB |
g++ | random_00 |
![]() |
6 ms | 4 MB |
g++ | random_01 |
![]() |
8 ms | 4 MB |
g++ | sparse_00 |
![]() |
6 ms | 4 MB |
g++ | sparse_01 |
![]() |
5 ms | 4 MB |
g++ | sparse_02 |
![]() |
5 ms | 4 MB |
g++ | sparse_03 |
![]() |
5 ms | 4 MB |
g++ | sparse_04 |
![]() |
5 ms | 4 MB |