F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_14925533_20346.cpp:11:6: error: wrong number of template arguments (0, should be 6)
 tree<>
      ^
In file included from 0_0_14925533_20346.cpp:5:0:
GCC4.9.2/x86_64-w64-mingw32/include/c++/ext/pb_ds/assoc_container.hpp:635:9: error: provided for 'template<class Key, class Mapped, class Cmp_Fn, class Tag, template<class Node_CItr, class Node_Itr, class Cmp_Fn_, class _Alloc_> class Node_Update, class _Alloc> class __gnu_pbds::tree'
   class tree : public PB_DS_TREE_BASE
         ^
0_0_14925533_20346.cpp:14:16: error: invalid type in declaration before '=' token
 const int MAXV = 100010;
                ^
0_0_14925533_20346.cpp:14:16: error: two or more data types in declaration of 'MAXV'
0_0_14925533_20346.cpp:15:18: error: 'MAXV' was not declared in this scope
 const int MAXE = MAXV << 1;
                  ^
0_0_14925533_20346.cpp:25:17: error: 'MAXV' was not declared in this scope
     } statePool[MAXV], *nil;
                 ^
0_0_14925533_20346.cpp:28:14: error: 'MAXV' was not declared in this scope
     int head[MAXV], val[MAXV], ecnt;
              ^
0_0_14925533_20346.cpp:28:25: error: 'MAXV' was not declared in this scope
     int head[MAXV], val[MAXV], ecnt;
                         ^
0_0_14925533_20346.cpp:29:16: error: size of array 'to' is not an integral constant-expression
     int to[MAXE], next[MAXE];
                ^
0_0_14925533_20346.cpp:29:28: error: size of array 'next' is not an integral constant-expression
     int to[MAXE], next[MAXE];
                            ^
0_0_14925533_20346.cpp:31:15: error: 'MAXV' was not declared in this scope
     Node *ptr[MAXV];
               ^
0_0_14925533_20346.cpp: In constructor 'LCT::LCT()':
0_0_14925533_20346.cpp:34:9: error: 'ptr' was not declared in this scope
         ptr[0] = nil = statePool;
         ^
0_0_14925533_20346.cpp:34:24: error: 'statePool' was not declared in this scope
         ptr[0] = nil = statePool;
                        ^
0_0_14925533_20346.cpp: In member function 'void LCT::init()':
0_0_14925533_20346.cpp:40:16: error: 'head' was not declared in this scope
         memset(head + 1, -1, n * sizeof(int));
                ^
0_0_14925533_20346.cpp: In member function 'void LCT::add_edge(int, int)':
0_0_14925533_20346.cpp:46:36: error: 'head' was not declared in this scope
         to[ecnt] = v; next[ecnt] = head[u]; head[u] = ecnt++;
                                    ^
0_0_14925533_20346.cpp: In member function 'LCT::Node* LCT::new_node(int, LCT::Node*)':
0_0_14925533_20346.cpp:51:20: error: 'statePool' was not declared in this scope
         Node* x = &statePool[ncnt++];
                    ^
0_0_14925533_20346.cpp: In member function 'void LCT::dfs(int, int)':
0_0_14925533_20346.cpp:62:9: error: 'ptr' was not declared in this scope
         ptr[u] = new_node(val[u], ptr[f]);
         ^
0_0_14925533_20346.cpp:62:27: error: 'val' was not declared in this scope
         ptr[u] = new_node(val[u], ptr[f]);
                           ^
0_0_14925533_20346.cpp:63:21: error: 'head' was not declared in this scope
         for(int p = head[u]; ~p; p = next[p]) {
                     ^
0_0_14925533_20346.cpp: In member function 'void LCT::work()':
0_0_14925533_20346.cpp:211:54: error: 'val' was not declared in this scope
             for(int i = 1; i <= n; ++i) scanf("%d", &val[i]);
                                                      ^
0_0_14925533_20346.cpp:222:25: error: 'ptr' was not declared in this scope
                     cut(ptr[x], ptr[y]);
                         ^
0_0_14925533_20346.cpp:226:32: error: 'ptr' was not declared in this scope
                     modify_set(ptr[a], ptr[b], x);
                                ^
0_0_14925533_20346.cpp:229:32: error: 'ptr' was not declared in this scope
                     modify_add(ptr[a], ptr[b], x);
                                ^
0_0_14925533_20346.cpp:232:27: error: 'ptr' was not declared in this scope
                     query(ptr[a], ptr[b]);
                           ^


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-11-22 16:53:32, Gzip enabled