encoder.cpp: In function 'void encode(int, int*)':
encoder.cpp:27:15: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int A=0;A<vec.size();A++)
~^~~~~~~~~~~
decoder.cpp: In function 'void decode(int, int, int*)':
decoder.cpp:19:15: error: expected initializer before '-' token
int res[1000]-{0};
^
In file included from /usr/include/c++/7/cassert:44:0,
from /usr/include/x86_64-linux-gnu/c++/7/bits/stdc++.h:33,
from decoder.cpp:3:
decoder.cpp:38:12: error: 'res' was not declared in this scope
assert(res[ind]==0);
^
decoder.cpp:42:16: error: 'res' was not declared in this scope
output(vec[res[A]]);
^~~