# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
152537 | Kamisama | Race (IOI11_race) | C++14 | 1185 ms | 33644 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 <iostream>
#include <cstdio>
#include <iomanip>
#include <chrono>
#include <vector>
using namespace std;
const int maxn=2e5+7;
const int maxk=1e6+7;
const int inf=1e9+7;
struct Edges{
int x,y,w;
};
int n,k,currentLab,res;
int subSize[maxn],lab[maxn],d[maxn],lv[maxn],f[maxk];
bool disabled[maxn];
vector<int> adj[maxn],tobeProcessed,depthList;
Edges e[maxn];
inline void CalcSize(const int &u){
lab[u]=currentLab;
subSize[u]=1;
for(int i: adj[u]){
int v=e[i].x+e[i].y-u;
if(disabled[v] || lab[v]==currentLab) continue;
CalcSize(v);
subSize[u]+=subSize[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... |