Submission #1007627

#TimeUsernameProblemLanguageResultExecution timeMemory
1007627nomuluunParrots (IOI11_parrots)C++14
Compilation error
0 ms0 KiB
#include<bits/stdc++.h> using namespace std; void send(int a); void output(int b); void encode(int N, int M[]){ for(int i=0; i<N; i++){ if(M[i]==1)send(i); } } void decode(int N, int L, int X[]){ bool b[10]={0}; for(int i=0; i<L; i++){ b[X[i]]=1; } for(int i=0; i<N; i++){ if(b[i]==1)output(1); else output(0); } }
#include<bits/stdc++.h> using namespace std; void send(int a); void output(int b); void encode(int N, int M[]){ for(int i=0; i<N; i++){ if(M[i]==1)send(i); } } void decode(int N, int L, int X[]){ bool b[10]={0}; for(int i=0; i<L; i++){ b[X[i]]=1; } for(int i=0; i<N; i++){ if(b[i]==1)output(1); else output(0); } }

Compilation message (stderr)

/usr/bin/ld: /tmp/cc5SS1VF.o: in function `decode(int, int, int*)':
encoder.cpp:(.text+0xc2): undefined reference to `output(int)'
/usr/bin/ld: encoder.cpp:(.text+0xd7): undefined reference to `output(int)'
collect2: error: ld returned 1 exit status

/usr/bin/ld: /tmp/cc60tePo.o: in function `encode(int, int*)':
decoder.cpp:(.text+0x37): undefined reference to `send(int)'
collect2: error: ld returned 1 exit status