# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
572681 | jlallas384 | Stranded Far From Home (BOI22_island) | C++17 | 286 ms | 48272 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>
using namespace std;
using ll = long long;
struct ufds{
vector<int> par;
ufds(int n): par(n){
iota(par.begin(), par.end(), 0);
}
int find(int a){
return a == par[a] ? a : par[a] = find(par[a]);
}
int unite(int a,int b){
a = find(a), b = find(b);
if(a == b) return 0;
par[b] = a;
return 1;
}
};
int main(){
ios::sync_with_stdio(false);
cin.tie(0);
int n,m;
cin >> n >> m;
vector<int> s(n);
for(int &x: s){
cin >> x;
}
vector<vector<int>> g(n);
# | 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... |