koala.cpp: In function 'void playRound(int*, int*)':
koala.cpp:12:16: error: 'N' was not declared in this scope
for (i=0;i<N;++i) {
^
koala.cpp:13:37: error: 'W' was not declared in this scope
if ( !(B[i] >= 0 && B[i] <= W) ) {
^
koala.cpp:19:13: error: 'W' was not declared in this scope
if (S > W) {
^
koala.cpp:24:5: error: 'numQueries' was not declared in this scope
numQueries++;
^~~~~~~~~~
koala.cpp:25:22: error: 'maxQueries' was not declared in this scope
if (numQueries > maxQueries) {
^~~~~~~~~~
koala.cpp:39:16: error: 'N' was not declared in this scope
for (i=0;i<N;++i) {
^
koala.cpp:43:21: error: 'W' was not declared in this scope
for (j=0;j<=W;++j) {
^
koala.cpp:48:16: error: 'W' was not declared in this scope
for (j=W;j>=v;--j) {
^
koala.cpp:49:37: error: 'P' was not declared in this scope
int h = cache[o][j-v] + P[i];
^
koala.cpp:61:15: error: 'W' was not declared in this scope
int cur = W;
^
koala.cpp:62:12: error: 'N' was not declared in this scope
for (i=N-1;i>=0;--i) {
^
koala.cpp: In function 'void runGame(int)':
koala.cpp:71:20: error: 'N' was not declared in this scope
scanf("%d %d",&N,&W);
^
koala.cpp:71:23: error: 'W' was not declared in this scope
scanf("%d %d",&N,&W);
^
koala.cpp:73:21: error: 'P' was not declared in this scope
scanf("%d",&P[i]);
^
koala.cpp:76:5: error: 'numQueries' was not declared in this scope
numQueries = 0;
^~~~~~~~~~
koala.cpp: In function 'int allValues(int, int, int*)':
koala.cpp:138:5: error: ambiguating new declaration of 'int allValues(int, int, int*)'
int allValues(int n, int w, int *P) {
^~~~~~~~~
In file included from koala.cpp:1:0:
koala.h:9:6: note: old declaration 'void allValues(int, int, int*)'
void allValues(int N, int W, int *P);
^~~~~~~~~
koala.cpp: At global scope:
koala.cpp:94:13: warning: 'void grader()' defined but not used [-Wunused-function]
static void grader() {
^~~~~~