Problem uniquenumbers
User Ningja
Submission Time 2023-11-08 14:06:53
Score 0
Max Time N/A
Max Memory N/A

Compile Error

uniquenumbers.cpp: In function ‘int main()’:
uniquenumbers.cpp:16:18: error: cannot convert ‘std::set<int>::iterator’ {aka ‘std::_Rb_tree_const_iterator<int>’} to ‘int’ in initialization
16 | int b1 = s.find(i);
| ~~~~~~^~~
| |
| std::set<int>::iterator {aka std::_Rb_tree_const_iterator<int>}
uniquenumbers.cpp:17:18: error: cannot convert ‘std::set<int>::iterator’ {aka ‘std::_Rb_tree_const_iterator<int>’} to ‘int’ in initialization
17 | int b2 = s.find(i-1);
| ~~~~~~^~~~~
| |
| std::set<int>::iterator {aka std::_Rb_tree_const_iterator<int>}