int hack(){
vector<int> v={1,2};
while(v[1]++)if(collisions(v))return v[1]-1;
}
컴파일 시 표준 에러 (stderr) 메시지
hack.cpp: In function 'int hack()':
hack.cpp:2:1: error: 'vector' was not declared in this scope
2 | vector<int> v={1,2};
| ^~~~~~
hack.cpp:2:8: error: expected primary-expression before 'int'
2 | vector<int> v={1,2};
| ^~~
hack.cpp:3:7: error: 'v' was not declared in this scope
3 | while(v[1]++)if(collisions(v))return v[1]-1;
| ^
hack.cpp:3:17: error: 'collisions' was not declared in this scope
3 | while(v[1]++)if(collisions(v))return v[1]-1;
| ^~~~~~~~~~