/ Vijos /

记录详情

Compile Error

/in/foo.cc: In function 'void add(int, int)':
/in/foo.cc:17:2: error: reference to 'next' is ambiguous
  next[tot]=point[x];
  ^~~~
/in/foo.cc:10:21: note: candidates are: int next [40030]
 int n,m,point[N*10],next[N*10],v[N*10],dis[N*10],vis[N*10],ans,inf,tot;
                     ^~~~
In file included from /usr/include/c++/7/bits/stl_algobase.h:66:0,
                 from /usr/include/c++/7/bits/char_traits.h:39,
                 from /usr/include/c++/7/ios:40,
                 from /usr/include/c++/7/ostream:38,
                 from /usr/include/c++/7/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/7/bits/stl_iterator_base_funcs.h:208:5: note:                 template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
     next(_ForwardIterator __x, typename
     ^~~~
/in/foo.cc: In function 'void find1(long long int, int, int)':
/in/foo.cc:23:5: warning: unused variable 'l' [-Wunused-variable]
  LL l=minn;
     ^
/in/foo.cc:24:5: warning: unused variable 'r' [-Wunused-variable]
  LL r=maxn;
     ^
/in/foo.cc: In function 'void find2(long long int, int, int)':
/in/foo.cc:37:5: warning: unused variable 'l' [-Wunused-variable]
  LL l=minn;
     ^
/in/foo.cc:38:5: warning: unused variable 'r' [-Wunused-variable]
  LL r=maxn;
     ^
/in/foo.cc: In function 'void bfs()':
/in/foo.cc:100:31: error: reference to 'next' is ambiguous
   for (int i=point[now]; i; i=next[i]) {
                               ^~~~
/in/foo.cc:10:21: note: candidates are: int next [40030]
 int n,m,point[N*10],next[N*10],v[N*10],dis[N*10],vis[N*10],ans,inf,tot;
                     ^~~~
In file included from /usr/include/c++/7/bits/stl_algobase.h:66:0,
                 from /usr/include/c++/7/bits/char_traits.h:39,
                 from /usr/include/c++/7/ios:40,
                 from /usr/include/c++/7/ostream:38,
                 from /usr/include/c++/7/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/7/bits/stl_iterator_base_funcs.h:208:5: note:                 template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
     next(_ForwardIterator __x, typename
     ^~~~

信息

递交者
类型
递交
题目
P1366 冰原探险
语言
C++
递交时间
2018-12-13 21:29:20
评测时间
2018-12-13 21:29:20
评测机
分数
0
总耗时
351ms
峰值内存
43.816 MiB