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_33384114_15828.cpp:3:5: error: 'string' does not name a type
     string s;
     ^
0_0_33384114_15828.cpp:5:29: error: 'string' has not been declared
     Node(int _num, int _id, string _s){
                             ^
0_0_33384114_15828.cpp: In constructor 'Node::Node(int, int, int)':
0_0_33384114_15828.cpp:6:31: error: 's' was not declared in this scope
         num = _num, id = _id, s = _s;
                               ^
0_0_33384114_15828.cpp: In member function 'bool Node::operator<(const Node&) const':
0_0_33384114_15828.cpp:9:51: error: 's' was not declared in this scope
         return num < rhs.num || num == rhs.num && s > rhs.s;
                                                   ^
0_0_33384114_15828.cpp:9:59: error: 'const struct Node' has no member named 's'
         return num < rhs.num || num == rhs.num && s > rhs.s;
                                                           ^
0_0_33384114_15828.cpp: At global scope:
0_0_33384114_15828.cpp:12:1: error: 'vector' does not name a type
 vector<int> v[10];
 ^
0_0_33384114_15828.cpp:15:16: error: 'MAXN' was not declared in this scope
     int sz, ch[MAXN][26], vis[MAXN];
                ^
0_0_33384114_15828.cpp:15:31: error: 'MAXN' was not declared in this scope
     int sz, ch[MAXN][26], vis[MAXN];
                               ^
0_0_33384114_15828.cpp:25:17: error: 'string' has not been declared
     void insert(string& s, int& x){
                 ^
0_0_33384114_15828.cpp:33:5: error: 'priority_queue' does not name a type
     priority_queue<Node> q, qq;
     ^
0_0_33384114_15828.cpp:34:16: error: 'string' has not been declared
     void query(string& s){
                ^
0_0_33384114_15828.cpp: In member function 'void Trie::init()':
0_0_33384114_15828.cpp:17:37: error: 'ch' was not declared in this scope
         for(int i = 0; i < 26; i++) ch[0][i] = 0;
                                     ^
0_0_33384114_15828.cpp: In member function 'int Trie::newnode()':
0_0_33384114_15828.cpp:21:37: error: 'ch' was not declared in this scope
         for(int i = 0; i < 26; i++) ch[sz][i] = 0;
                                     ^
0_0_33384114_15828.cpp:22:9: error: 'vis' was not declared in this scope
         vis[sz] = 0;
         ^
0_0_33384114_15828.cpp: In member function 'void Trie::insert(int&, int&)':
0_0_33384114_15828.cpp:26:19: error: request for member 'size' in 's', which is of non-class type 'int'
         int n = s.size(), p = 0, c;
                   ^
0_0_33384114_15828.cpp:28:13: error: 'c' was not declared in this scope
             c = s[i] - 'a';
             ^
0_0_33384114_15828.cpp:28:20: error: invalid types 'int[int]' for array subscript
             c = s[i] - 'a';
                    ^
0_0_33384114_15828.cpp:29:17: error: 'ch' was not declared in this scope
             if(!ch[p][c]) ch[p][c] = newnode();
                 ^
0_0_33384114_15828.cpp:29:20: error: 'p' was not declared in this scope
             if(!ch[p][c]) ch[p][c] = newnode();
                    ^
0_0_33384114_15828.cpp:30:13: error: 'p' was not declared in this scope
             p = ch[p][c], vis[p] += x;
             ^
0_0_33384114_15828.cpp:30:17: error: 'ch' was not declared in this scope
             p = ch[p][c], vis[p] += x;
                 ^
0_0_33384114_15828.cpp:30:27: error: 'vis' was not declared in this scope
             p = ch[p][c], vis[p] += x;
                           ^
0_0_33384114_15828.cpp: In member function 'void Trie::query(int&)':
0_0_33384114_15828.cpp:35:19: error: request for member 'size' in 's', which is of non-class type 'int'
         int n = s.size() - 1, p, c;
                   ^
0_0_33384114_15828.cpp:36:15: error: 'q' was not declared in this scope
         while(q.size()) q.pop();
               ^
0_0_33384114_15828.cpp:37:15: error: 'qq' was not declared in this scope
         while(qq.size()) qq.pop();
               ^
0_0_33384114_15828.cpp:38:9: error: 'q' was not declared in this scope
         q.push(Node(0, 0, ""));
         ^
0_0_33384114_15828.cpp:38:29: error: invalid conversion from 'const char*' to 'int' [-fpermissive]
         q.push(Node(0, 0, ""));
                             ^
0_0_33384114_15828.cpp:5:5: note: initializing argument 3 of 'Node::Node(int, int, int)'
     Node(int _num, int _id, string _s){
     ^
0_0_33384114_15828.cpp:40:13: error: 'c' was not declared in this scope
             c = s[i] - '0';
             ^
0_0_33384114_15828.cpp:40:20: error: invalid types 'int[int]' for array subscript
             c = s[i] - '0';
                    ^
0_0_33384114_15828.cpp:43:17: error: 'p' was not declared in this scope
                 p = tmp.id;
                 ^
0_0_33384114_15828.cpp:44:30: error: 'v' was not declared in this scope
                 for(int& x : v[c]){
                              ^
0_0_33384114_15828.cpp:45:25: error: 'ch' was not declared in this scope
                     if(!ch[p][x]) continue;
                         ^
0_0_33384114_15828.cpp:46:21: error: 'qq' was not declared in this scope
                     qq.push(Node(vis[ch[p][x]], ch[p][x], tmp.s + ((char)(x+'a'))));
                     ^
0_0_33384114_15828.cpp:46:34: error: 'vis' was not declared in this scope
                     qq.push(Node(vis[ch[p][x]], ch[p][x], tmp.s + ((char)(x+'a'))));
                                  ^
0_0_33384114_15828.cpp:46:38: error: 'ch' was not declared in this scope
                     qq.push(Node(vis[ch[p][x]], ch[p][x], tmp.s + ((char)(x+'a'))));
                                      ^
0_0_33384114_15828.cpp:46:63: error: 'struct Node' has no member named 's'
                     qq.push(Node(vis[ch[p][x]], ch[p][x], tmp.s + ((char)(x+'a'))));
                                                               ^
0_0_33384114_15828.cpp:49:17: error: 'qq' was not declared in this scope
             if(!qq.size()) { DEBUG(no); continue; }
                 ^
0_0_33384114_15828.cpp:49:36: error: 'no' was not declared in this scope
             if(!qq.size()) { DEBUG(no); continue; }
                                    ^
0_0_33384114_15828.cpp:49:38: error: 'DEBUG' was not declared in this scope
             if(!qq.size()) { DEBUG(no); continue; }
                                      ^
0_0_33384114_15828.cpp:50:19: error: 'qq' was not declared in this scope
             DEBUG(qq.top().s);
                   ^
0_0_33384114_15828.cpp:50:29: error: 'DEBUG' was not declared in this scope
             DEBUG(qq.top().s);
                             ^
0_0_33384114_15828.cpp:51:23: error: 'swap' was not declared in this scope
             swap(q, qq);
                       ^
0_0_33384114_15828.cpp: In function 'void run(int)':
0_0_33384114_15828.cpp:56:5: error: 'cout' was not declared in this scope
     cout << "Scenario #" << cas << ":\n";
     ^
0_0_33384114_15828.cpp:58:18: error: 'string' was not declared in this scope
     int n, m, x; string s;
                  ^
0_0_33384114_15828.cpp:59:9: error: 'cin' was not declared in this scope
     for(cin >> n; n--;){
         ^
0_0_33384114_15828.cpp:60:16: error: 's' was not declared in this scope
         cin >> s >> x;
                ^
0_0_33384114_15828.cpp:63:9: error: 'cin' was not declared in this scope
     for(cin >> m; m--;){
         ^
0_0_33384114_15828.cpp:64:16: error: 's' was not declared in this scope
         cin >> s;
                ^
0_0_33384114_15828.cpp: In function 'int main()':
0_0_33384114_15828.cpp:74:5: error: 'ios' has not been declared
     ios::sync_with_stdio(false);
     ^
0_0_33384114_15828.cpp:79:13: error: 'v' was not declared in this scope
             v[i].push_back(k++);
             ^
0_0_33384114_15828.cpp:81:9: error: 'v' was not declared in this scope
         v[7].push_back(k++);
         ^
0_0_33384114_15828.cpp:83:9: error: 'v' was not declared in this scope
         v[8].push_back(k++);
         ^
0_0_33384114_15828.cpp:85:9: error: 'v' was not declared in this scope
         v[9].push_back(k++);
         ^
0_0_33384114_15828.cpp:86:25: error: 'cin' was not declared in this scope
     int T, cas = 0; for(cin >> T; T--;) run(++cas); return 0;
                         ^


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-26 08:14:43, Gzip enabled