제출 #490872

#제출 시각아이디문제언어결과실행 시간메모리
490872niloyrootLost in the cycle (IOI19_cycle)C++14
컴파일 에러
0 ms0 KiB
#include <bits/stdc++.h> using namespace std; using ll = long long; using vi = vector<ll>; using pl = pair<ll,ll>; #define pb push_back #define form(m,it) for(auto it=m.begin(); it!=m.end(); it++) #define forp(i,a,b) for(ll i=a; i<=b; i++) #define forn(i,a,b) for(ll i=a; i>=b; i--) #define newl '\n' #define ff first #define ss second const ll mod = 1000000007; void escape(int n){ ll len=1; while(len<n){ len*=2; } len/=2; bool g=1; while(len>=1){ if(g){ g=jump(len); } else { g=jump(n-len); } len/=2; } jump(1); if(jump(n-1)){ return; } else { jump(n-1); } }

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

cycle.cpp: In function 'void escape(int)':
cycle.cpp:24:15: error: 'jump' was not declared in this scope
   24 |             g=jump(len);
      |               ^~~~
cycle.cpp:26:15: error: 'jump' was not declared in this scope
   26 |             g=jump(n-len);
      |               ^~~~
cycle.cpp:30:5: error: 'jump' was not declared in this scope
   30 |     jump(1);
      |     ^~~~