QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#189860#4037. Absolute Pairwise Distancealch07Compile Error//C++144.0kb2023-09-28 00:52:262023-09-28 00:52:26

詳細信息

answer.code:27:9: error: ‘piar’ was not declared in this scope
   27 | vector <piar<int,int>> items;
      |         ^~~~
answer.code:27:21: error: template argument 1 is invalid
   27 | vector <piar<int,int>> items;
      |                     ^~
answer.code:27:21: error: template argument 2 is invalid
answer.code: In function ‘int main()’:
answer.code:60:15: error: request for member ‘push_back’ in ‘items’, which is of non-class type ‘int’
   60 |         items.push_back(make_pair(x, i));
      |               ^~~~~~~~~
answer.code:62:16: error: request for member ‘begin’ in ‘items’, which is of non-class type ‘int’
   62 |     sort(items.begin(), items.end());
      |                ^~~~~
answer.code:62:31: error: request for member ‘end’ in ‘items’, which is of non-class type ‘int’
   62 |     sort(items.begin(), items.end());
      |                               ^~~
answer.code:66:17: error: invalid types ‘int[int]’ for array subscript
   66 |         if(items[i].first > prv){
      |                 ^
answer.code:69:16: error: invalid types ‘int[int]’ for array subscript
   69 |         a[items[i].second] = cur;
      |                ^
answer.code:70:20: error: invalid types ‘int[int]’ for array subscript
   70 |         prv = items[i].first;
      |                    ^
answer.code:81:9: error: ‘qv’ was not declared in this scope; did you mean ‘q’?
   81 |         qv.push_back({l, r, i});
      |         ^~
      |         q
answer.code:83:10: error: ‘qv’ was not declared in this scope; did you mean ‘q’?
   83 |     sort(qv.begin(), qv.end());
      |          ^~
      |          q
answer.code:88:9: error: ‘fxx’ was not declared in this scope
   88 |         fxx[i] = sq.query(a[i]);
      |         ^~~
answer.code:88:21: error: ‘struct SqrtStruct’ has no member named ‘query’
   88 |         fxx[i] = sq.query(a[i]);
      |                     ^~~~~
answer.code:89:12: error: ‘struct SqrtStruct’ has no member named ‘add’
   89 |         sq.add(a[i]);
      |            ^~~
answer.code:90:9: error: ‘fxp1x’ was not declared in this scope
   90 |         fxp1x[i] = sq.query(a[i]-1);
      |         ^~~~~
answer.code:90:23: error: ‘struct SqrtStruct’ has no member named ‘query’
   90 |         fxp1x[i] = sq.query(a[i]-1);
      |                       ^~~~~
answer.code:94:9: error: ‘additions’ was not declared in this scope
   94 |         additions[i] = 0;
      |         ^~~~~~~~~
answer.code:102:17: error: ‘additions’ was not declared in this scope
  102 |                 additions[i] += /*f(curR+1, a[j]-1)*/(- fxp1x[j]);
      |                 ^~~~~~~~~
answer.code:102:57: error: ‘fxp1x’ was not declared in this scope
  102 |                 additions[i] += /*f(curR+1, a[j]-1)*/(- fxp1x[j]);
      |                                                         ^~~~~
answer.code:104:13: error: ‘movs’ was not declared in this scope
  104 |             movs[curR+1].push_back({qv[i].l, curL-1, true, i, 1});
      |             ^~~~
answer.code:109:17: error: ‘additions’ was not declared in this scope
  109 |                 additions[i] += ((j-1) - (curL) + 1) - (fxx[j]/* - f(curL, a[j])*/);
      |                 ^~~~~~~~~
answer.code:109:57: error: ‘fxx’ was not declared in this scope
  109 |                 additions[i] += ((j-1) - (curL) + 1) - (fxx[j]/* - f(curL, a[j])*/);
      |                                                         ^~~
answer.code:111:13: error: ‘movs’ was not declared in this scope
  111 |             movs[curL].push_back({curR+1, qv[i].r, false, i, 1});
      |             ^~~~
answer.code:116:17: error: ‘additions’ was not declared in this scope
  116 |                 additions[i] -= /*f(curR+1, a[j]-1)*/(- fxp1x[j]);
      |                 ^~~~~~~~~
answer.code:116:57: error: ‘fxp1x’ was not declared in this scope
  116 |                 additions[i] -= /*f(curR+1, a[j]-1)*/(- fxp1x[j]);
      |                                                         ^~~~~
answer.code:118:13: error: ‘movs’ was not declared in this scope
  118 |             movs[curR+1].push_back({curL, qv[i].l-1, true, i, -1});
      |             ^~~~
answer.code:123:17: error: ‘additions’ was not declared in this scope
  123 |                 additions[i] -= ((j-1) - (curL) + 1) - (fxx[j]/* - f(curL, a[j])*/);
      |                 ^~~~~~~~~
answer.code:123:57: error: ‘fxx’ was not declared in this scope
  123 |                 additions[i] -= ((j-1) - (curL) + 1) - (fxx[j]/* - f(curL, a[j])*/);
      |                                                         ^~~
answer.code:125:13: error: ‘movs’ was not declared in this scope
  125 |             movs[curL].push_back({(qv[i].r+1), curR, false, i, -1});
      |             ^~~~
answer.code:130:8: error: ‘struct SqrtStruct’ has no member named ‘clear’
  130 |     sq.clear();
      |        ^~~~~
answer.code:132:28: error: ‘movs’ was not declared in this scope
  132 |         for(int j = 0; j < movs[i].size(); j++){
      |                            ^~~~
answ...