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_13910411_5137.cpp:17:1: error: reference to 'tuple' is ambiguous
 tuple pos[MAXN],s1,s2;
 ^
0_0_13910411_5137.cpp:10:23: note: candidates are: typedef struct std::pair<int, int> tuple
 typedef pair<int,int> tuple;
                       ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/utility:70:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:60,
                 from 0_0_13910411_5137.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:83:11: note:                 template<class ...> class std::tuple
     class tuple;
           ^
0_0_13910411_5137.cpp:17:1: error: 'tuple' does not name a type
 tuple pos[MAXN],s1,s2;
 ^
0_0_13910411_5137.cpp:24:22: error: reference to 'tuple' is ambiguous
 inline int dis(const tuple& a,const tuple& b){
                      ^
0_0_13910411_5137.cpp:10:23: note: candidates are: typedef struct std::pair<int, int> tuple
 typedef pair<int,int> tuple;
                       ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/utility:70:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:60,
                 from 0_0_13910411_5137.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:83:11: note:                 template<class ...> class std::tuple
     class tuple;
           ^
0_0_13910411_5137.cpp:24:22: error: 'tuple' does not name a type
 inline int dis(const tuple& a,const tuple& b){
                      ^
0_0_13910411_5137.cpp:24:37: error: reference to 'tuple' is ambiguous
 inline int dis(const tuple& a,const tuple& b){
                                     ^
0_0_13910411_5137.cpp:10:23: note: candidates are: typedef struct std::pair<int, int> tuple
 typedef pair<int,int> tuple;
                       ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/utility:70:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:60,
                 from 0_0_13910411_5137.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:83:11: note:                 template<class ...> class std::tuple
     class tuple;
           ^
0_0_13910411_5137.cpp:24:37: error: 'tuple' does not name a type
 inline int dis(const tuple& a,const tuple& b){
                                     ^
0_0_13910411_5137.cpp: In function 'int dis(const int&, const int&)':
0_0_13910411_5137.cpp:25:15: error: request for member 'first' in 'a', which is of non-class type 'const int'
  return abs(a.first-b.first)+abs(a.second-b.second);
               ^
0_0_13910411_5137.cpp:25:23: error: request for member 'first' in 'b', which is of non-class type 'const int'
  return abs(a.first-b.first)+abs(a.second-b.second);
                       ^
0_0_13910411_5137.cpp:25:36: error: request for member 'second' in 'a', which is of non-class type 'const int'
  return abs(a.first-b.first)+abs(a.second-b.second);
                                    ^
0_0_13910411_5137.cpp:25:45: error: request for member 'second' in 'b', which is of non-class type 'const int'
  return abs(a.first-b.first)+abs(a.second-b.second);
                                             ^
0_0_13910411_5137.cpp: In function 'void tarjan(int)':
0_0_13910411_5137.cpp:49:29: error: reference to 'next' is ambiguous
  for(int e=first[u];e!=-1;e=next[e]){
                             ^
0_0_13910411_5137.cpp:14:23: note: candidates are: int next [500000]
 int N,A,B,first[MAXN],next[MAXM],e_num,e_num_bak,dfn[MAXN],low[MAXN],scc_num,scc_belong[MAXN],dfs_time,d_road,dist1[MAXK][MAXK],dist2[MAXK][MAXK],first_bak[MAXN];
                       ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:66:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:61,
                 from 0_0_13910411_5137.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:184:5: note:                 template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
     next(_ForwardIterator __x, typename
     ^
0_0_13910411_5137.cpp: In function 'void add(int, int)':
0_0_13910411_5137.cpp:70:2: error: reference to 'next' is ambiguous
  next[e_num] = first[u];
  ^
0_0_13910411_5137.cpp:14:23: note: candidates are: int next [500000]
 int N,A,B,first[MAXN],next[MAXM],e_num,e_num_bak,dfn[MAXN],low[MAXN],scc_num,scc_belong[MAXN],dfs_time,d_road,dist1[MAXK][MAXK],dist2[MAXK][MAXK],first_bak[MAXN];
                       ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:66:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:61,
                 from 0_0_13910411_5137.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:184:5: note:                 template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
     next(_ForwardIterator __x, typename
     ^
0_0_13910411_5137.cpp: In function 'int main()':
0_0_13910411_5137.cpp:124:2: error: reference to 'tuple' is ambiguous
  tuple hate_list[MAXN],friend_list[MAXN];
  ^
0_0_13910411_5137.cpp:10:23: note: candidates are: typedef struct std::pair<int, int> tuple
 typedef pair<int,int> tuple;
                       ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/utility:70:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:60,
                 from 0_0_13910411_5137.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:83:11: note:                 template<class ...> class std::tuple
     class tuple;
           ^
0_0_13910411_5137.cpp:126:20: error: 's1' was not declared in this scope
  scanf("%d%d%d%d",&s1.first,&s1.second,&s2.first,&s2.second);
                    ^
0_0_13910411_5137.cpp:126:41: error: 's2' was not declared in this scope
  scanf("%d%d%d%d",&s1.first,&s1.second,&s2.first,&s2.second);
                                         ^
0_0_13910411_5137.cpp:127:37: error: 'pos' was not declared in this scope
  for(int i=0;i<N;i++) scanf("%d%d",&pos[i].first,&pos[i].second);
                                     ^
0_0_13910411_5137.cpp:128:38: error: 'hate_list' was not declared in this scope
  for(int i=1;i<=A;i++) scanf("%d%d",&hate_list[i].first,&hate_list[i].second);
                                      ^
0_0_13910411_5137.cpp:129:38: error: 'friend_list' was not declared in this scope
  for(int i=1;i<=B;i++) scanf("%d%d",&friend_list[i].first,&friend_list[i].second);
                                      ^
0_0_13910411_5137.cpp:133:9: error: 'hate_list' was not declared in this scope
   id1 = hate_list[i].first-1 , id2 = hate_list[i].second-1;
         ^
0_0_13910411_5137.cpp:141:9: error: 'friend_list' was not declared in this scope
   id1 = friend_list[i].first-1 , id2 = friend_list[i].second-1;
         ^
0_0_13910411_5137.cpp:150:21: error: 'pos' was not declared in this scope
   dist1[i][j] = dis(pos[i],s1)+dis(pos[j],s1);
                     ^


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-11-29 22:27:14, Gzip enabled