(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 #298580

#TimeUsernameProblemLanguageResultExecution timeMemory
298580ak2006Traffic (IOI10_traffic)C++14
Compilation error
0 ms0 KiB
#include <bits/stdc++.h> using namespace std; #define int long long int32_t main() { int n; cin>>n; vector<int>p(n); int tot = 0; for(int i = 0;i<n;i++){cin>>p[i];tot+=p[i];} vector<vector<int>>adj(n); for(int i = 0;i<n-1;i++){int a,b;cin>>a>>b;adj[a].push_back(b);adj[b].push_back(a);} int ans = 1e15,cur = 0; for(int i = 0;i<n;i++){ans = min(ans,max(cur,tot-cur));} cout<<ans; return 0; }

Compilation message (stderr)

/tmp/ccSIlE0M.o: In function `main':
grader.cpp:(.text.startup+0x0): multiple definition of `main'
/tmp/ccb2rLiz.o:traffic.cpp:(.text.startup+0x0): first defined here
/tmp/ccSIlE0M.o: In function `main':
grader.cpp:(.text.startup+0xad): undefined reference to `LocateCentre(int, int*, int*, int*)'
collect2: error: ld returned 1 exit status