# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
587775 | almothana05 | Connecting Supertrees (IOI20_supertrees) | C++14 | 230 ms | 22240 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 "supertrees.h"
#include <vector>
#include<bits/stdc++.h>
using namespace std;
vector<vector<int> >erg;
vector<int>cmp[2000] , comp;
int vis[2000] , visi[2000] , f[2000];
set<int> s;
int construct(vector<vector<int>> p) {
int menge = p.size() , pl = 1;
for(int i = 0 ; i < menge ; i++){
erg.push_back(vector<int>() );
for(int j = 0 ; j < menge ; j++){
erg[i].push_back(0);
}
}
for(int i = 0 ; i < menge ; i++){
if(p[i][i] != 1){
return 0;
}
p[i][i] = 1;
}
for(int i = 0 ; i < menge ; i++){
if(vis[i] == 0){
vis[i] = pl;
for(int j = 0 ; j < menge ; j++){
if(p[i][j] == 1){
cmp[pl].push_back(j);
vis[j] = pl;
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... |