# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1074685 | khanhtb | Bridges (APIO19_bridges) | C++14 | 1967 ms | 524288 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
#define ll long long
#define ull unsigned long long
#define ld long double
#define pb push_back
#define pf push_front
#define vi vector<int>
#define vii vector<vi>
#define pll pair<int, int>
#define vpll vector<pint>
#define all(a) a.begin(), a.end()
#define fi first
#define se second
using namespace std;
const int mod = 1e9+7;
const ll inf = 2e18;
const int B = 320;
const int N = 1e5 + 8;
struct DSU_roll_back{
vector<int> par,sz;
vector<pair<int &,int>> history;
void init(int n){
par = vector<int> (n+5);
sz = vector<int> (n+5,1);
iota(all(par),0);
}
int fs(int v){
return par[v] == v?v:fs(par[v]);
}
void us(int u, int v){
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |