Submission #1362062

#TimeUsernameProblemLanguageResultExecution timeMemory
1362062srividya_06Koala Game (APIO17_koala)C++20
Compilation error
0 ms0 KiB
#include <bits/stdc++.h>
#define REP(i,a,b) for(int i = a; i<b; i++)
#define RREP(i,a,b) for(int i = a; i>b; i--)
using namespace std;
int b[100],r[100];
int minValue(int N, int W){
    fill(b, b+N,0);
    b[0] = 1;
    playRound(b,r);
    if(r[0]<=1) return 0;
    REP(i,1,N){
        if(r[i]>0) return i;
    }
}
int maxValue(int N, int W){
    return 0;
}
bool greaterValue(int N, int W){
    return 0;
}
void allValues(int N, int W, int *P){
}

Compilation message (stderr)

koala.cpp: In function 'int minValue(int, int)':
koala.cpp:9:5: error: 'playRound' was not declared in this scope; did you mean 'lround'?
    9 |     playRound(b,r);
      |     ^~~~~~~~~
      |     lround
koala.cpp:14:1: warning: control reaches end of non-void function [-Wreturn-type]
   14 | }
      | ^