QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#319933#8217. King's Dinnerucup-team598#Compile Error//C++142.0kb2024-02-03 12:06:282024-02-03 12:06:28

Details

answer.code: In function ‘int main()’:
answer.code:30:9: error: ‘vector’ was not declared in this scope
   30 |         vector<vector<int>> a(n, vector<int>(n));
      |         ^~~~~~
answer.code:4:1: note: ‘std::vector’ is defined in header ‘<vector>’; did you forget to ‘#include <vector>’?
    3 | #include <cstring>
  +++ |+#include <vector>
    4 | using namespace std;
answer.code:30:23: error: expected primary-expression before ‘int’
   30 |         vector<vector<int>> a(n, vector<int>(n));
      |                       ^~~
answer.code:42:17: error: ‘a’ was not declared in this scope
   42 |                 a[i][j] = 1;
      |                 ^
answer.code:49:17: error: ‘a’ was not declared in this scope
   49 |                 a[i][n - 1] = 1;
      |                 ^
answer.code:55:17: error: ‘a’ was not declared in this scope
   55 |                 a[n - 3][i] = 1;
      |                 ^
answer.code:62:17: error: ‘a’ was not declared in this scope
   62 |                 a[n - 1][i] = 1;
      |                 ^
answer.code:67:13: error: ‘a’ was not declared in this scope
   67 |             a[n - 1][n - 1] = 1;
      |             ^
answer.code:72:21: error: ‘a’ was not declared in this scope
   72 |                 if (a[i][j]) cout << "#";
      |                     ^