제출 #1267162

#제출 시각아이디문제언어결과실행 시간메모리
1267162somefolkMemory (IOI10_memory)C++20
컴파일 에러
0 ms0 KiB
#include <bits/stdc++.h> #include "grader.h" #include "memory.h" using namespace std; const int n = 50; void play(){ unordered_map<int, char> mp; for(int i = 1; i <= n; i++){ int ans = faceup(i); mp[i] = ans; } unordered_map<char, vector<int>> mp2; for(auto &i : mp){ mp2[i.second].push_back(i.first); } for(auto &i : mp2){ faceup(i.second[0], i.second[1]); } }

컴파일 시 표준 에러 (stderr) 메시지

memory.cpp: In function 'void play()':
memory.cpp:21:15: error: too many arguments to function 'char faceup(int)'
   21 |         faceup(i.second[0], i.second[1]);
      |         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from memory.cpp:2:
grader.h:1:6: note: declared here
    1 | char faceup(int C);
      |      ^~~~~~