F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_39228125_7239.cpp: In function 'void qnext(int*, int)':
0_0_39228125_7239.cpp:17:9: error: reference to 'next' is ambiguous
   17 |         next[0]=-1;
      |         ^~~~
In file included from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_algobase.h:66,
                 from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/algorithm:60,
                 from 0_0_39228125_7239.cpp:2:
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_iterator_base_funcs.h:232:5: note: candidates are: 'template<class _InputIterator> constexpr _InputIterator std::next(_InputIterator, typename iterator_traits<_Iter>::difference_type)'
  232 |     next(_InputIterator __x, typename
      |     ^~~~
0_0_39228125_7239.cpp:11:5: note:                 'int next [200000]'
   11 | int next[200000];
      |     ^~~~
0_0_39228125_7239.cpp:23:33: error: reference to 'next' is ambiguous
   23 |                                 next[p]=q;
      |                                 ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_iterator_base_funcs.h:232:5: note: candidates are: 'template<class _InputIterator> constexpr _InputIterator std::next(_InputIterator, typename iterator_traits<_Iter>::difference_type)'
  232 |     next(_InputIterator __x, typename
      |     ^~~~
0_0_39228125_7239.cpp:11:5: note:                 'int next [200000]'
   11 | int next[200000];
      |     ^~~~
0_0_39228125_7239.cpp:25:33: error: reference to 'next' is ambiguous
   25 |                                 next[p]=next[q];
      |                                 ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_iterator_base_funcs.h:232:5: note: candidates are: 'template<class _InputIterator> constexpr _InputIterator std::next(_InputIterator, typename iterator_traits<_Iter>::difference_type)'
  232 |     next(_InputIterator __x, typename
      |     ^~~~
0_0_39228125_7239.cpp:11:5: note:                 'int next [200000]'
   11 | int next[200000];
      |     ^~~~
0_0_39228125_7239.cpp:25:41: error: reference to 'next' is ambiguous
   25 |                                 next[p]=next[q];
      |                                         ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_iterator_base_funcs.h:232:5: note: candidates are: 'template<class _InputIterator> constexpr _InputIterator std::next(_InputIterator, typename iterator_traits<_Iter>::difference_type)'
  232 |     next(_InputIterator __x, typename
      |     ^~~~
0_0_39228125_7239.cpp:11:5: note:                 'int next [200000]'
   11 | int next[200000];
      |     ^~~~
0_0_39228125_7239.cpp:28:27: error: reference to 'next' is ambiguous
   28 |                         q=next[q];
      |                           ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_iterator_base_funcs.h:232:5: note: candidates are: 'template<class _InputIterator> constexpr _InputIterator std::next(_InputIterator, typename iterator_traits<_Iter>::difference_type)'
  232 |     next(_InputIterator __x, typename
      |     ^~~~
0_0_39228125_7239.cpp:11:5: note:                 'int next [200000]'
   11 | int next[200000];
      |     ^~~~
0_0_39228125_7239.cpp: In function 'void kmp(int*, int*, int, int)':
0_0_39228125_7239.cpp:43:27: error: reference to 'next' is ambiguous
   43 |                         q=next[q];
      |                           ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_iterator_base_funcs.h:232:5: note: candidates are: 'template<class _InputIterator> constexpr _InputIterator std::next(_InputIterator, typename iterator_traits<_Iter>::difference_type)'
  232 |     next(_InputIterator __x, typename
      |     ^~~~
0_0_39228125_7239.cpp:11:5: note:                 'int next [200000]'
   11 | int next[200000];
      |     ^~~~
0_0_39228125_7239.cpp: In function 'int main()':
0_0_39228125_7239.cpp:59:24: error: reference to 'next' is ambiguous
   59 |                 memset(next,0,sizeof(next));
      |                        ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_iterator_base_funcs.h:232:5: note: candidates are: 'template<class _InputIterator> constexpr _InputIterator std::next(_InputIterator, typename iterator_traits<_Iter>::difference_type)'
  232 |     next(_InputIterator __x, typename
      |     ^~~~
0_0_39228125_7239.cpp:11:5: note:                 'int next [200000]'
   11 | int next[200000];
      |     ^~~~
0_0_39228125_7239.cpp:59:38: error: reference to 'next' is ambiguous
   59 |                 memset(next,0,sizeof(next));
      |                                      ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_iterator_base_funcs.h:232:5: note: candidates are: 'template<class _InputIterator> constexpr _InputIterator std::next(_InputIterator, typename iterator_traits<_Iter>::difference_type)'
  232 |     next(_InputIterator __x, typename
      |     ^~~~
0_0_39228125_7239.cpp:11:5: note:                 'int next [200000]'
   11 | int next[200000];
      |     ^~~~


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-07-06 13:22:04, Gzip enabled