제출 #1304226

#제출 시각아이디문제언어결과실행 시간메모리
1304226activedeltorreGondola (IOI14_gondola)C++20
컴파일 에러
0 ms0 KiB
#include "gondola.h" #include<map> using namespace std; map<int,int>fre; int valid(int n, int inputSeq[]) { int offset=-1,val,off2; fre.clear(); for(int i=1;i<=n;i++) { val=inputSeq[i-1]; fre[val]++; if(fre[val]>=2) { return 0; } if(val<=0) { return 0; } if(val<=n && offset==-1) { offset=(i-val+n)%n; } else if(val<=n) { off2=(i-val+n)%n; if(off2!=offset) { return 0; } } } return 1; }

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

/usr/bin/ld: /tmp/ccgz62Y9.o: in function `main':
grader.cpp:(.text.startup+0xfc): undefined reference to `replacement'
/usr/bin/ld: grader.cpp:(.text.startup+0x18d): undefined reference to `countReplacement'
collect2: error: ld returned 1 exit status