Submission #792296

#TimeUsernameProblemLanguageResultExecution timeMemory
792296limabeansRace (IOI11_race)C++17
Compilation error
0 ms0 KiB
#include <algorithm> #include <iostream> #include <vector> #include <cassert> using namespace std; using ll = long long; const int maxn=2e5+10; int n,k; vector<pair<ll,int>> g[maxn]; int main() { ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0); cin>>n>>k; vector<pair<int,int>> edges; vector<ll> wei; for (int i=0; i<n-1; i++) { int u,v; cin>>u>>v; edges.push_back({u,v}); } for (int i=0; i<n-1; i++) { ll w; cin>>w; wei.push_back(w); } for (int i=0; i<n-1; i++) { int u=edges[i].first; int v=edges[i].second; ll w=wei[i]; g[u].push_back({w,v}); g[v].push_back({w,u}); } cout<<1<<endl; return 0; }

Compilation message (stderr)

/usr/bin/ld: /tmp/cc5UBsX6.o: in function `main':
race.cpp:(.text.startup+0x0): multiple definition of `main'; /tmp/ccA0bGk9.o:grader.cpp:(.text.startup+0x0): first defined here
/usr/bin/ld: /tmp/ccA0bGk9.o: in function `main':
grader.cpp:(.text.startup+0x28): undefined reference to `best_path(int, int, int (*) [2], int*)'
collect2: error: ld returned 1 exit status