제출 #1256279

#제출 시각아이디문제언어결과실행 시간메모리
1256279nlknHack (APIO25_hack)C++20
컴파일 에러
0 ms0 KiB
#include "hack.h" #include <bits/stdc++.h> using namespace std; 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:7:28: error: could not convert 'v' from 'vector<int>' to 'vector<long long int>'
    7 | while(v[1]++)if(collisions(v))return v[1]-1;
      |                            ^
      |                            |
      |                            vector<int>
hack.cpp:8:1: warning: control reaches end of non-void function [-Wreturn-type]
    8 | }
      | ^