QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#514329#51. TilingGuanYunchangCompile Error//C++98404b2024-08-11 00:37:312024-08-11 00:37:31

Details

answer.code:3:7: error: expected nested-name-specifier before ‘ll’
    3 | using ll = long long;
      |       ^~
answer.code: In function ‘int main()’:
answer.code:7:13: error: ‘ll’ was not declared in this scope
    7 |     vector <ll> f(w, -1),g(w, -1);
      |             ^~
answer.code:7:15: error: template argument 1 is invalid
    7 |     vector <ll> f(w, -1),g(w, -1);
      |               ^
answer.code:7:15: error: template argument 2 is invalid
answer.code:7:24: error: expression list treated as compound expression in initializer [-fpermissive]
    7 |     vector <ll> f(w, -1),g(w, -1);
      |                        ^
answer.code:7:33: error: expression list treated as compound expression in initializer [-fpermissive]
    7 |     vector <ll> f(w, -1),g(w, -1);
      |                                 ^
answer.code:8:6: error: invalid types ‘int[int]’ for array subscript
    8 |     g[0] = 0, g[1] = 1;
      |      ^
answer.code:8:16: error: invalid types ‘int[int]’ for array subscript
    8 |     g[0] = 0, g[1] = 1;
      |                ^
answer.code:9:6: error: invalid types ‘int[int]’ for array subscript
    9 |     f[0] = 1, f[1] = 0;
      |      ^
answer.code:9:16: error: invalid types ‘int[int]’ for array subscript
    9 |     f[0] = 1, f[1] = 0;
      |                ^
answer.code:10:12: error: expected ‘;’ before ‘i’
   10 |     for (ll i = 2; i < w; i++) {
      |            ^~
      |            ;
answer.code:10:20: error: ‘i’ was not declared in this scope
   10 |     for (ll i = 2; i < w; i++) {
      |                    ^
answer.code:14:7: error: expected ‘;’ before ‘n’
   14 |     ll n;
      |       ^~
      |       ;
answer.code:15:12: error: ‘n’ was not declared in this scope
   15 |     cin >> n;
      |            ^
answer.code:16:7: error: expected ‘;’ before ‘k’
   16 |     ll k;
      |       ^~
      |       ;
answer.code:17:5: error: ‘k’ was not declared in this scope
   17 |     k = f[n];
      |     ^