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

Compile Error

deforestation.cpp: In function ‘int main()’:
deforestation.cpp:7:27: error: template argument 2 is invalid
7 | map <int,<pair<int,int>> m;
| ^
deforestation.cpp:7:27: error: template argument 4 is invalid
deforestation.cpp:11:3: error: ‘m’ was not declared in this scope
11 | m.insert(make_pair(A,B));
| ^
deforestation.cpp:22:13: error: expected ‘;’ before ‘}’ token
22 | sum += B
| ^
| ;
23 | }
| ~
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_iterator<int>}