Submission #567625

#TimeUsernameProblemLanguageResultExecution timeMemory
567625losmi247Memory (IOI10_memory)C++14
Compilation error
0 ms0 KiB
#include <bits/stdc++.h>
#include "memory.h"
#include "grader.h"
using namespace std;
typedef long long ll;

string s;
int faceup(int x){
    return s[x-1];
}

void play(){
    for(int i = 1; i <= 50; i++){
        for(int j = i+1; j <= 50; j++){
            int h = faceup(i);
            int g = faceup(j);
            if(h == g) return;
        }
    }
}

Compilation message (stderr)

memory.cpp:8:5: error: ambiguating new declaration of 'int faceup(int)'
    8 | int faceup(int x){
      |     ^~~~~~
In file included from memory.cpp:3:
grader.h:1:6: note: old declaration 'char faceup(int)'
    1 | char faceup(int C);
      |      ^~~~~~