제출 #581635

#제출 시각아이디문제언어결과실행 시간메모리
581635zaneyuFinding Routers (IOI20_routers)C++14
컴파일 에러
0 ms0 KiB
#include "lampposts.h" #include<bits/stdc++.h> using namespace std; #define f first #define s second map<int,int> mp; std::vector<int> find_routers(int L, int N, int A[]) { vector<int> A(N); for(int i=1;i<N;i++){ int l=A[i-1],r=L; for(auto x:mp){ if(x.s==i-1) l=x.f; } for(auto x:mp){ if(x.s>=i){ r=x.f; break; } } while(l<r){ int mid=(l+r+1)/2; if(!mp.count(mid)) mp[mid]=use_detector(mid); if(mp[mid]==i-1) l=mid; else r=mid-1; } A[i]=A[i-1]+(l-A[i-1])*2; } }

컴파일 시 표준 에러 (stderr) 메시지

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