xylophone.cpp: In function 'bool check_permutation(int)':
xylophone.cpp:5:5: error: 'set' was not declared in this scope
5 | set<int> s;
| ^~~
xylophone.cpp:5:5: note: suggested alternatives:
In file included from /usr/include/c++/10/set:61,
from xylophone.cpp:2:
/usr/include/c++/10/bits/stl_set.h:94:11: note: 'std::set'
94 | class set
| ^~~
In file included from xylophone.cpp:2:
/usr/include/c++/10/set:78:13: note: 'std::pmr::set'
78 | using set = std::set<_Key, _Cmp, polymorphic_allocator<_Key>>;
| ^~~
xylophone.cpp:5:9: error: expected primary-expression before 'int'
5 | set<int> s;
| ^~~
xylophone.cpp:6:34: error: 's' was not declared in this scope
6 | for (int i = 1; i <= n; ++i) s.insert(a[i]);
| ^
xylophone.cpp:7:9: error: 's' was not declared in this scope
7 | if (s.size() != n) return false;
| ^
xylophone.cpp:8:11: error: 's' was not declared in this scope
8 | if (*(s.begin()) != 1) return false;
| ^
xylophone.cpp:9:14: error: 's' was not declared in this scope
9 | auto k = s.end();
| ^
xylophone.cpp: In function 'void build_permutation1(int)':
xylophone.cpp:27:12: error: 'min_element' was not declared in this scope
27 | int mi = *min_element(a+1, a+n+1) - 1;
| ^~~~~~~~~~~
xylophone.cpp: In function 'void build_permutation2(int)':
xylophone.cpp:42:12: error: 'min_element' was not declared in this scope
42 | int mi = *min_element(a+1, a+n+1) - 1;
| ^~~~~~~~~~~