Problem | catlunch |
---|---|
User | justin271828 |
Submission Time | 2023-06-14 12:14:58 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
catlunch.cpp: In function ‘int main()’:
catlunch.cpp:29:19: error: invalid use of non-static member function ‘std::priority_queue<_Tp, _Sequence, _Compare>::const_reference std::priority_queue<_Tp, _Sequence, _Compare>::top() const [with _Tp = int; _Sequence = std::vector<int>; _Compare = std::less<int>; std::priority_queue<_Tp, _Sequence, _Compare>::const_reference = const int&]’
29 | cout << max(maxi.top, a+b);
| ~~~~~^~~
In file included from /usr/include/c++/9/queue:64,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:86,
from catlunch.cpp:1:
/usr/include/c++/9/bits/stl_queue.h:612:7: note: declared here
612 | top() const
| ^~~