結果
| 問題 | No.3668 Minimum Cut |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2026-09-04 23:58:19 |
| 言語 | C++23(gcc16) (gcc 16.1.0 + boost 1.92.0) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 1,806 bytes |
| 記録 | |
| コンパイル時間 | 5,638 ms |
| コンパイル使用メモリ | 372,668 KB |
| 実行使用メモリ | 6,272 KB |
| 最終ジャッジ日時 | 2026-09-04 23:58:35 |
| 合計ジャッジ時間 | 10,848 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 21 TLE * 1 -- * 17 |
ソースコード
// ACLでは通らんやろな
#pragma GCC target("avx2")
#pragma GCC optimize("O3")
#pragma GCC optimize("unroll-loops")
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/hash_policy.hpp>
using namespace std;
using namespace __gnu_pbds;
#include <atcoder/maxflow>
// using mint = atcoder::modint998244353;
using ll = long long;
#define rep(i, n) for (ll i = 0; i < (ll)(n); ++i)
// const ll dy[] = {-1, -1, -1, 0, 0, 1, 1, 1};
// const ll dx[] = {-1, 0, 1, -1, 1, -1, 0, 1};
const ll dy[] = {-1, 0, 0, 1};
const ll dx[] = {0, -1, 1, 0};
template <class T, class T1, class T2> bool isrange(T target, T1 low, T2 high) { return low <= target && target < high; }
template <class T, class U> T min(const T &t, const U &u) { return t < u ? t : u; }
template <class T, class U> T max(const T &t, const U &u) { return t < u ? u : t; }
template <class T, class U> bool chmin(T &t, const U &u) { if (t > u) { t = u; return true; } return false; }
template <class T, class U> bool chmax(T &t, const U &u) { if (t < u) { t = u; return true; } return false; }
template<class K, class V> using hash_map = gp_hash_table<K, V>;
template<class K> using hash_set = gp_hash_table<K, null_type>;
// #include "titan_cpplib/others/io.cpp"
// #include "titan_cpplib/others/print.cpp"
void solve() {
int n, m, s, t; cin >> n >> m >> s >> t;
--s; --t;
atcoder::mf_graph<ll> G(n);
rep(i, m) {
int u, v, c; cin >> u >> v >> c;
--u; --v;
G.add_edge(u, v, c);
}
cout << G.flow(s, t) << "\n";
}
int main() {
ios::sync_with_stdio(false);
cin.tie(0);
cout << fixed << setprecision(15);
cerr << fixed << setprecision(15);
int t = 1;
// cin >> t;
for (int i = 0; i < t; ++i) {
solve();
}
return 0;
}