Problem deforestation
User blob
Submission Time 2023-11-24 13:34:00
Score 0
Max Time N/A
Max Memory N/A

Compile Error

deforestation.cpp: In function ‘int main()’:
deforestation.cpp:6:6: error: expected unqualified-id before ‘<<’ token
6 | map <<int><pair<int,int>> m;
| ^~
deforestation.cpp:9:3: error: ‘m’ was not declared in this scope
9 | m.insert(make_pair(A,B));
| ^
deforestation.cpp:14:17: error: ‘m’ was not declared in this scope
14 | s.insert(sort (m.begin(), m.end()));
| ^
deforestation.cpp:22:5: error: ‘sum’ was not declared in this scope
22 | sum += B
| ^~~
deforestation.cpp:26:7: error: no match for ‘operator<<’ (operand types are ‘std::ostream’ {aka ‘std::basic_ostream<char>’} and ‘std::set<int>::iterator’ {aka ‘std::_Rb_tree_const_iterator<int>’})
26 | cout << s.begin():
| ~~~~ ^~ ~~~~~~~~~
| | |
| | std::set<int>::iterator {aka std::_Rb_tree_const_iterato