QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#548518#9161. Naval battle5un_xiaomivita_mboxCompile Error//C++234.3kb2024-09-05 19:03:512024-09-05 19:03:51

Details

In file included from /usr/include/c++/13/map:62,
                 from /usr/include/x86_64-linux-gnu/c++/13/bits/stdc++.h:152,
                 from answer.code:1:
/usr/include/c++/13/bits/stl_tree.h: In instantiation of ‘static const _Key& std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_S_key(_Const_Link_type) [with _Key = point; _Val = point; _KeyOfValue = std::_Identity<point>; _Compare = cmp2; _Alloc = std::allocator<point>; _Const_Link_type = const std::_Rb_tree_node<point>*]’:
/usr/include/c++/13/bits/stl_tree.h:2020:37:   required from ‘std::pair<std::_Rb_tree_iterator<_Val>, std::_Rb_tree_iterator<_Val> > std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::equal_range(const _Key&) [with _Key = point; _Val = point; _KeyOfValue = std::_Identity<point>; _Compare = cmp2; _Alloc = std::allocator<point>]’
/usr/include/c++/13/bits/stl_tree.h:2519:49:   required from ‘std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::size_type std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::erase(const _Key&) [with _Key = point; _Val = point; _KeyOfValue = std::_Identity<point>; _Compare = cmp2; _Alloc = std::allocator<point>; size_type = long unsigned int]’
/usr/include/c++/13/bits/stl_set.h:687:26:   required from ‘std::set<_Key, _Compare, _Alloc>::size_type std::set<_Key, _Compare, _Alloc>::erase(const key_type&) [with _Key = point; _Compare = cmp2; _Alloc = std::allocator<point>; size_type = long unsigned int; key_type = point]’
answer.code:46:25:   required from here
/usr/include/c++/13/bits/stl_tree.h:772:15: error: static assertion failed: comparison object must be invocable as const
  772 |               is_invocable_v<const _Compare&, const _Key&, const _Key&>,
      |               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/13/bits/stl_tree.h:772:15: note: ‘std::is_invocable_v<const cmp2&, const point&, const point&>’ evaluates to false
/usr/include/c++/13/bits/stl_tree.h: In instantiation of ‘static const _Key& std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_S_key(_Const_Link_type) [with _Key = point; _Val = point; _KeyOfValue = std::_Identity<point>; _Compare = cmp1; _Alloc = std::allocator<point>; _Const_Link_type = const std::_Rb_tree_node<point>*]’:
/usr/include/c++/13/bits/stl_tree.h:2020:37:   required from ‘std::pair<std::_Rb_tree_iterator<_Val>, std::_Rb_tree_iterator<_Val> > std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::equal_range(const _Key&) [with _Key = point; _Val = point; _KeyOfValue = std::_Identity<point>; _Compare = cmp1; _Alloc = std::allocator<point>]’
/usr/include/c++/13/bits/stl_tree.h:2519:49:   required from ‘std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::size_type std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::erase(const _Key&) [with _Key = point; _Val = point; _KeyOfValue = std::_Identity<point>; _Compare = cmp1; _Alloc = std::allocator<point>; size_type = long unsigned int]’
/usr/include/c++/13/bits/stl_set.h:687:26:   required from ‘std::set<_Key, _Compare, _Alloc>::size_type std::set<_Key, _Compare, _Alloc>::erase(const key_type&) [with _Key = point; _Compare = cmp1; _Alloc = std::allocator<point>; size_type = long unsigned int; key_type = point]’
answer.code:47:22:   required from here
/usr/include/c++/13/bits/stl_tree.h:772:15: error: static assertion failed: comparison object must be invocable as const
/usr/include/c++/13/bits/stl_tree.h:772:15: note: ‘std::is_invocable_v<const cmp1&, const point&, const point&>’ evaluates to false
/usr/include/c++/13/bits/stl_tree.h: In instantiation of ‘static const _Key& std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_S_key(_Const_Link_type) [with _Key = point1; _Val = point1; _KeyOfValue = std::_Identity<point1>; _Compare = cmp; _Alloc = std::allocator<point1>; _Const_Link_type = const std::_Rb_tree_node<point1>*]’:
/usr/include/c++/13/bits/stl_tree.h:2118:47:   required from ‘std::pair<std::_Rb_tree_node_base*, std::_Rb_tree_node_base*> std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_M_get_insert_unique_pos(const key_type&) [with _Key = point1; _Val = point1; _KeyOfValue = std::_Identity<point1>; _Compare = cmp; _Alloc = std::allocator<point1>; key_type = point1]’
/usr/include/c++/13/bits/stl_tree.h:2171:4:   required from ‘std::pair<std::_Rb_tree_iterator<_Val>, bool> std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_M_insert_unique(_Arg&&) [with _Arg = point1; _Key = point1; _Val = point1; _KeyOfValue = std::_Identity<point1>; _Compare = cmp; _Alloc = std::allocator<point1>]’
/usr/include/c++/13/bits/stl_set.h:523:25:   required from ‘std::pair<typename std::_Rb_tree<_Key, _Key, std::_Identity<_Tp>, _Compare, typename __gnu_cxx::__alloc_traits<_Alloc>::rebind<_Key>::other>::const_iterator, bool> std::set<_Key, _Compare, _Alloc>::insert(value_type&&) [with _Key = point1; _Compare = cmp; _Alloc = std::allocator<point1>; typename std::_Rb_tree<_Key, _Key, std::_Identity<_Tp>, _Compare, typename __gnu_c...