Submission #412489

#TimeUsernameProblemLanguageResultExecution timeMemory
412489jeqchoRace (IOI11_race)C++17
Compilation error
0 ms0 KiB
#include "grader.h" #include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int,int> pii; typedef vector<int> vi; typedef vector<pair<int,int>> vpi; #define FOR(i,a,b) for (int i = (a); i < (b); ++i) #define F0R(i,a) FOR(i,0,a) #define ROF(i,a,b) for (int i = (b)-1; i >= (a); --i) #define R0F(i,a) ROF(i,0,a) #define trav(a,x) for (auto& a: x) #define pb push_back #define rsz resize #define sz(x) int(x.size()) #define all(x) begin(x), end(x) #define fi first #define se second int const n=2e5+3; vpi adj[n]; int const INF=1e9; // subtask 1,2 int dfs(int now, int par, int w, int k) { if(w > k)return INF; if(w==k)return 0; int mn=INF; trav(chi,adj[now]) { if(chi.fi==par)continue; mn=min(mn,1+dfs(chi.fi,now,w+chi.se,k)); } return mn; } int best_path(int N, int K, int H[][2], int L[]){ F0R(i,N-1) { int u = H[i][0]; int v = H[i][1]; adj[u].pb({v,L[i]}); adj[v].pb({u,L[i]}); } int mn=INF; F0R(i,N) { mn=min(mn,dfs(i,-1,0,K)); } if(mn>=INF)return -1; return mn; }

Compilation message (stderr)

race.cpp:1:10: fatal error: grader.h: No such file or directory
    1 | #include "grader.h"
      |          ^~~~~~~~~~
compilation terminated.