QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#756623#415. 最小生成树ucup-team4777Compile Error//C++20983b2024-11-16 21:14:542024-11-16 21:14:56

详细

answer.code: In function ‘void solve()’:
answer.code:22:5: error: ‘vectotr’ was not declared in this scope
   22 |     vectotr<int> p(n + 1);
      |     ^~~~~~~
answer.code:5:13: error: expected primary-expression before ‘long’
    5 | #define int long long
      |             ^~~~
answer.code:22:13: note: in expansion of macro ‘int’
   22 |     vectotr<int> p(n + 1);
      |             ^~~
answer.code:23:36: error: ‘p’ was not declared in this scope
   23 |     for(int i = 1 ; i <= n ; i ++) p[i] = i;
      |                                    ^
answer.code: In lambda function:
answer.code:25:20: error: ‘p’ was not declared in this scope
   25 |         while(x != p[x]) x = p[x] = p[p[x]];
      |                    ^
answer.code: In function ‘void solve()’:
answer.code:5:13: error: expected ‘,’ or ‘;’ before ‘long’
    5 | #define int long long
      |             ^~~~
answer.code:28:5: note: in expansion of macro ‘int’
   28 |     int ans = 0;
      |     ^~~
answer.code:32:13: error: ‘p’ was not declared in this scope
   32 |             p[v] = u;
      |             ^
answer.code:33:13: error: ‘ans’ was not declared in this scope; did you mean ‘abs’?
   33 |             ans += w;
      |             ^~~
      |             abs
answer.code:36:13: error: ‘w’ was not declared in this scope
   36 |     cout << w << endl;
      |             ^