제출 #947428

#제출 시각아이디문제언어결과실행 시간메모리
947428phoenix0423Stray Cat (JOI20_stray)C++17
컴파일 에러
0 ms0 KiB
#include "Catherine.h" #include <vector> #include<bits/stdc++.h> using namespace std; int A, B, lst = -1, move = 0, ok = 0; string ps = ""; void Init(int a, int b){ A = a, B = b; } int Move(vector<int> y){ // cout<<"ck : "<<A<<" "<<B<<"\n"; if(lst != -1) y[lst]++; int deg = accumulate(y.begin(), y.end(), 0); if(deg == 1){ return max_element(y.begin(), y.end()) - y.begin(); } if(true){ for(int i = 0; i < A; i++){ // cout<<"try : "<<y[i]<<" "<<y[(i + 1) % A]<<"\n"; if(y[i] == 1 && y[(i + 1) % A]){ return i; } } } return 0; if(deg > 2){ if(lst) return lst ^ 1; else return y[0] != 1; } if(ok){ } } /* 7 6 3 6 1 0 2 0 4 1 2 1 3 1 5 4 6 */

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

/usr/bin/ld: /tmp/ccHq0MMn.o: in function `main':
grader_anthony.cpp:(.text.startup+0x191): undefined reference to `Mark(int, int, int, int, std::vector<int, std::allocator<int> >, std::vector<int, std::allocator<int> >)'
collect2: error: ld returned 1 exit status

/usr/bin/ld: /tmp/ccvm19J9.o: in function `main':
grader_catherine.cpp:(.text.startup+0x41c): undefined reference to `Init(int, int)'
/usr/bin/ld: grader_catherine.cpp:(.text.startup+0xcfa): undefined reference to `Move(std::vector<int, std::allocator<int> >)'
collect2: error: ld returned 1 exit status