Problem deathray
User PerihelionfromAphelion
Submission Time 2026-05-01 12:39:42
Score 0
Max Time N/A
Max Memory N/A

Compile Error

deathray.cpp: In function ‘int main()’:
deathray.cpp:5:2: error: ‘ios_sync_with_stdio’ was not declared in this scope
5 | ios_sync_with_stdio(false);
| ^~~~~~~~~~~~~~~~~~~
deathray.cpp:24:28: error: invalid use of member function ‘std::priority_queue<_Tp, _Sequence, _Compare>::const_reference std::priority_queue<_Tp, _Sequence, _Compare>::top() const [with _Tp = long long int; _Sequence = std::vector<long long int>; _Compare = std::greater<long long int>; std::priority_queue<_Tp, _Sequence, _Compare>::const_reference = const long long int&]’ (did you forget the ‘()’ ?)
24 | while (!pq.empty() && pq.top <= total_damage) {
| ~~~^~~
| ()
deathray.cpp:28:3: error: ‘else’ without a previous ‘if’
28 | else if (c == 'B') {
| ^~~~