/ Vijos /

记录详情

Compile Error

/in/foo.cc:179:15: error: stray '@' in program
  179 |  chronix LV 8 @ 8 年前
      |               ^
/in/foo.cc:181:16: error: extended character 。 is not valid in an identifier
  181 | 位运算储存状态+SPFA,以状态为节点。
      |                ^
/in/foo.cc: In function 'void bfs()':
/in/foo.cc:114:7: warning: unused variable 'j' [-Wunused-variable]
  114 | int i,j;
      |       ^
/in/foo.cc: At global scope:
/in/foo.cc:177:1: error: expected unqualified-id before numeric constant
  177 | 0
      | ^
In file included from /usr/include/x86_64-linux-gnu/c++/12/bits/c++allocator.h:33,
                 from /usr/include/c++/12/bits/allocator.h:46,
                 from /usr/include/c++/12/deque:61,
                 from /usr/include/c++/12/queue:60,
                 from /in/foo.cc:188:
/usr/include/c++/12/bits/new_allocator.h: In member function '_Tp* std::__new_allocator<_Tp>::allocate(size_type, const void*)':
/usr/include/c++/12/bits/new_allocator.h:125:20: error: '__throw_bad_array_new_length' is not a member of 'std'; did you mean 'bad_array_new_length'?
  125 |               std::__throw_bad_array_new_length();
      |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                    bad_array_new_length
/usr/include/c++/12/bits/new_allocator.h:126:18: error: '__throw_bad_alloc' is not a member of 'std'
  126 |             std::__throw_bad_alloc();
      |                  ^~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/12/deque:64:
/usr/include/c++/12/bits/stl_deque.h: In static member function 'static std::size_t std::deque<_Tp, _Alloc>::_S_check_init_len(std::size_t, const allocator_type&)':
/usr/include/c++/12/bits/stl_deque.h:1870:11: error: there are no arguments to '__throw_length_error' that depend on a template parameter, so a declaration of '__throw_length_error' must be available [-fpermissive]
 1870 |           __throw_length_error(
      |           ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_deque.h:1870:11: note: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
In file included from /usr/include/c++/12/deque:67:
/usr/include/c++/12/bits/deque.tcc: In member function 'void std::deque<_Tp, _Alloc>::_M_push_back_aux(_Args&& ...)':
/usr/include/c++/12/bits/deque.tcc:493:11: error: there are no arguments to '__throw_length_error' that depend on a template parameter, so a declaration of '__throw_length_error' must be available [-fpermissive]
  493 |           __throw_length_error(
      |           ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/deque.tcc: In member function 'void std::deque<_Tp, _Alloc>::_M_push_front_aux(_Args&& ...)':
/usr/include/c++/12/bits/deque.tcc:532:11: error: there are no arguments to '__throw_length_error' that depend on a template parameter, so a declaration of '__throw_length_error' must be available [-fpermissive]
  532 |           __throw_length_error(
      |           ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/deque.tcc: In member function 'void std::deque<_Tp, _Alloc>::_M_new_elements_at_front(size_type)':
/usr/include/c++/12/bits/deque.tcc:885:9: error: there are no arguments to '__throw_length_error' that depend on a template parameter, so a declaration of '__throw_length_error' must be available [-fpermissive]
  885 |         __throw_length_error(__N("deque::_M_new_elements_at_front"));
      |         ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/deque.tcc: In member function 'void std::deque<_Tp, _Alloc>::_M_new_elements_at_back(size_type)':
/usr/include/c++/12/bits/deque.tcc:910:9: error: there are no arguments to '__throw_length_error' that depend on a template parameter, so a declaration of '__throw_length_error' must be available [-fpermissive]
  910 |         __throw_length_error(__N("deque::_M_new_elements_at_back"));
      |         ^~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/12/vector:64,
                 from /usr/include/c++/12/queue:61:
/usr/include/c++/12/bits/stl_vector.h: In member function 'std::vector<_Tp, _Alloc>::size_type std::vector<_Tp, _Alloc>::_M_check_len(size_type, const char*) const':
/usr/include/c++/12/bits/stl_vector.h:1894:11: error: there are no arguments to '__throw_length_error' that depend on a template parameter, so a declaration of '__throw_length_error' must be available [-fpermissive]
 1894 |           __throw_length_error(__N(__s));
      |           ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_vector.h: In static member function 'static std::vector<_Tp, _Alloc>::size_type std::vector<_Tp, _Alloc>::_S_check_init_len(size_type, const allocator_type&)':
/usr/include/c++/12/bits/stl_vector.h:1905:11: error: there are no arguments to '__throw_length_error' that depend on a template parameter, so a declaration of '__throw_length_error' must be available [-fpermissive]
 1905 |           __throw_length_error(
      |           ^~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/12/vector:65:
/usr/include/c++/12/bits/stl_bvector.h: In member function 'void std::vector<bool, _Alloc>::reserve(size_type)':
/usr/include/c++/12/bits/stl_bvector.h:1077:11: error: there are no arguments to '__throw_length_error' that depend on a template parameter, so a declaration of '__throw_length_error' must be available [-fpermissive]
 1077 |           __throw_length_error(__N("vector::reserve"));
      |           ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_bvector.h: In member function 'std::vector<bool, _Alloc>::size_type std::vector<bool, _Alloc>::_M_check_len(size_type, const char*) const':
/usr/include/c++/12/bits/stl_bvector.h:1482:11: error: there are no arguments to '__throw_length_error' that depend on a template parameter, so a declaration of '__throw_length_error' must be available [-fpermissive]
 1482 |           __throw_length_error(__N(__s));
      |           ^~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/12/vector:70:
/usr/include/c++/12/bits/vector.tcc: In member function 'void std::vector<_Tp, _Alloc>::reserve(size_type)':
/usr/include/c++/12/bits/vector.tcc:71:9: error: there are no arguments to '__throw_length_error' that depend on a template parameter, so a declaration of '__throw_length_error' must be available [-fpermissive]
   71 |         __throw_length_error(__N("vector::reserve"));
      |         ^~~~~~~~~~~~~~~~~~~~
/in/foo.cc: At global scope:
/in/foo.cc:193:5: error: redefinition of 'int n'
  193 | int n,m,k,end,acc[3000],AG[20]={0};
      |     ^
/in/foo.cc:3:7: note: 'int n' previously declared here
    3 | int m,n,k;
      |       ^
/in/foo.cc:193:7: error: redefinition of 'int m'
  193 | int n,m,k,end,acc[3000],AG[20]={0};
      |       ^
/in/foo.cc:3:5: note: 'int m' previously declared here
    3 | int m,n,k;
      |     ^
/in/foo.cc:193:9: error: redefinition of 'int k'
  193 | int n,m,k,end,acc[3000],AG[20]={0};
      |         ^
/in/foo.cc:3:9: note: 'int k' previously declared here
    3 | int m,n,k;
      |         ^
/in/foo.cc:232:5: error: redefinition of 'int main()'
  232 | int main(){
      |     ^~~~
/in/foo.cc:159:5: note: 'int main()' previously defined here
  159 | int main()
      |     ^~~~
/usr/include/c++/12/bits/deque.tcc: In instantiation of 'void std::deque<_Tp, _Alloc>::_M_push_back_aux(_Args&& ...) [with _Args = {const int&}; _Tp = int; _Alloc = std::allocator<int>]':
/usr/include/c++/12/bits/stl_deque.h:1548:20:   required from 'void std::deque<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = int; _Alloc = std::allocator<int>; value_type = int]'
/usr/include/c++/12/bits/stl_queue.h:286:20:   required from 'void std::queue<_Tp, _Sequence>::push(const value_type&) [with _Tp = int; _Sequence = std::deque<int, std::allocator<int> >; value_type = int]'
/in/foo.cc:203:7:   required from here
/usr/include/c++/12/bits/deque.tcc:493:31: error: '__throw_length_error' was not declared in this scope
  493 |           __throw_length_error(
      |           ~~~~~~~~~~~~~~~~~~~~^
  494 |               __N("cannot create std::deque larger than max_size()"));
      |               ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

信息

递交者
类型
递交
题目
P1578 渡河
语言
C++
递交时间
2025-06-16 20:02:38
评测时间
2025-06-16 20:02:38
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes