Submission #1088625

#TimeUsernameProblemLanguageResultExecution timeMemory
1088625toast12Memory (IOI10_memory)C++14
Compilation error
0 ms0 KiB
#include <vector>
using namespace std;

void play() {
    vector<pair<int, int>> ans(25);
    char a, b;
    for (int i = 1; i <= 25; ++i) {
        a = faceup(i);
        b = faceup(51-i);
        if (ans[a-'A'].first != 0) {
            ans[a-'A'].second = i;
        }
        else {
            ans[a-'A'].first = i;
        }
        if (ans[b-'A'].first != 0) {
            ans[b-'A'].second = 51-i;
        }
        else {
            ans[b-'A'].first = 51-i;
        }
    }
    for (int i = 0; i < 25; i++) {
        faceup(ans[i].first);
        faceup(ans[i].second);
    }
    return;
}

Compilation message (stderr)

memory.cpp: In function 'void play()':
memory.cpp:8:13: error: 'faceup' was not declared in this scope
    8 |         a = faceup(i);
      |             ^~~~~~
memory.cpp:24:9: error: 'faceup' was not declared in this scope
   24 |         faceup(ans[i].first);
      |         ^~~~~~