(UPD: 2024-12-04 14:48 UTC) Judge is not working due to Cloudflare incident. (URL) We can do nothing about it, sorry. After the incident is resolved, we will grade all submissions.

Submission #1123641

#TimeUsernameProblemLanguageResultExecution timeMemory
1123641codexistentTraffic (IOI10_traffic)C11
Compilation error
0 ms0 KiB
#include "traffic.h" #include <bits/stdc++.h> using namespace std; #define ll long long #define MAXN 1000005 #define FOR(i, a, b) for(ll i = a; i <= b; i++) ll r[MAXN], s = 0, cgd[MAXN]; vector<ll> adj[MAXN]; pair<ll, ll> ans; void dfs(ll i, ll p = -1){ for(ll i2 : adj[i]) if(i2 != p) { dfs(i2, i); r[i] = max(r[i], cgd[i2]); cgd[i] += cgd[i2]; } r[i] = max(r[i], s - cgd[i]); } int LocateCentre(int N, int pp[], int S[], int D[]) { FOR(i, 0, n - 2) adj[S[i]].push_back(D[i]), adj[D[i]].push_back(S[i]); FOR(i, 0, n - 1) cgu[i] = pp[i], cgd[i] = {0, 0}, s += pp[i]; dfs(0); ans = {LLONG_MAX, LLONG_MAX}; FOR(i, 0, n - 1) ans = min(ans, {r[i], i}); return ans.second; }

Compilation message (stderr)

traffic.c:2:10: fatal error: bits/stdc++.h: No such file or directory
    2 | #include <bits/stdc++.h>
      |          ^~~~~~~~~~~~~~~
compilation terminated.