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_33476668_28812.cpp: In function 'int main()':
0_0_33476668_28812.cpp:26:24: error: 'Node' was not declared in this scope
         priority_queue<Node> p1;
                        ^
0_0_33476668_28812.cpp:26:28: error: template argument 1 is invalid
         priority_queue<Node> p1;
                            ^
0_0_33476668_28812.cpp:26:28: error: template argument 2 is invalid
0_0_33476668_28812.cpp:26:28: error: template argument 3 is invalid
0_0_33476668_28812.cpp:26:32: error: invalid type in declaration before ';' token
         priority_queue<Node> p1;
                                ^
0_0_33476668_28812.cpp:27:24: error: the value of 'Node' is not usable in a constant expression
         priority_queue<Node> p2;
                        ^
0_0_33476668_28812.cpp:26:24: note: 'Node' was not declared 'constexpr'
         priority_queue<Node> p1;
                        ^
0_0_33476668_28812.cpp:27:28: error: type/value mismatch at argument 1 in template parameter list for 'template<class _Tp, class _Sequence, class _Compare> class std::priority_queue'
         priority_queue<Node> p2;
                            ^
0_0_33476668_28812.cpp:27:28: error:   expected a type, got 'Node'
0_0_33476668_28812.cpp:27:28: error: template argument 2 is invalid
0_0_33476668_28812.cpp:27:28: error: template argument 3 is invalid
0_0_33476668_28812.cpp:27:32: error: invalid type in declaration before ';' token
         priority_queue<Node> p2;
                                ^
0_0_33476668_28812.cpp:28:24: error: the value of 'Node' is not usable in a constant expression
         priority_queue<Node> p3;
                        ^
0_0_33476668_28812.cpp:26:24: note: 'Node' was not declared 'constexpr'
         priority_queue<Node> p1;
                        ^
0_0_33476668_28812.cpp:28:28: error: type/value mismatch at argument 1 in template parameter list for 'template<class _Tp, class _Sequence, class _Compare> class std::priority_queue'
         priority_queue<Node> p3;
                            ^
0_0_33476668_28812.cpp:28:28: error:   expected a type, got 'Node'
0_0_33476668_28812.cpp:28:28: error: template argument 2 is invalid
0_0_33476668_28812.cpp:28:28: error: template argument 3 is invalid
0_0_33476668_28812.cpp:28:32: error: invalid type in declaration before ';' token
         priority_queue<Node> p3;
                                ^
0_0_33476668_28812.cpp:39:25: error: 'h' was not declared in this scope
                 cin>>a>>h.x;
                         ^
0_0_33476668_28812.cpp:43:24: error: request for member 'push' in 'p1', which is of non-class type 'int'
                     p1.push(h);
                        ^
0_0_33476668_28812.cpp:47:24: error: request for member 'push' in 'p2', which is of non-class type 'int'
                     p2.push(h);
                        ^
0_0_33476668_28812.cpp:50:24: error: request for member 'push' in 'p3', which is of non-class type 'int'
                     p3.push(h);
                        ^
0_0_33476668_28812.cpp:57:27: error: request for member 'empty' in 'p1', which is of non-class type 'int'
                     if(p1.empty())
                           ^
0_0_33476668_28812.cpp:61:34: error: request for member 'top' in 'p1', which is of non-class type 'int'
                         cout<<p1.top().y<<endl;
                                  ^
0_0_33476668_28812.cpp:62:28: error: request for member 'pop' in 'p1', which is of non-class type 'int'
                         p1.pop();
                            ^
0_0_33476668_28812.cpp:67:27: error: request for member 'empty' in 'p2', which is of non-class type 'int'
                     if(p2.empty())
                           ^
0_0_33476668_28812.cpp:71:34: error: request for member 'top' in 'p2', which is of non-class type 'int'
                         cout<<p2.top().y<<endl;
                                  ^
0_0_33476668_28812.cpp:72:28: error: request for member 'pop' in 'p2', which is of non-class type 'int'
                         p2.pop();
                            ^
0_0_33476668_28812.cpp:78:27: error: request for member 'empty' in 'p3', which is of non-class type 'int'
                     if(p3.empty())
                           ^
0_0_33476668_28812.cpp:82:34: error: request for member 'top' in 'p3', which is of non-class type 'int'
                         cout<<p3.top().y<<endl;
                                  ^
0_0_33476668_28812.cpp:83:28: error: request for member 'pop' in 'p3', which is of non-class type 'int'
                         p3.pop();
                            ^


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-10-02 21:19:15, Gzip enabled