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_25304930_10629.cpp: In function 'void dijkstra(int, int)':
0_0_25304930_10629.cpp:28:13: error: reference to 'distance' is ambiguous
      dis[i]=distance[src][i];
             ^
0_0_25304930_10629.cpp:9:5: note: candidates are: int distance [1010][1010]
 int distance[maxn][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++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_25304930_10629.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:114:5: note:                 template<class _InputIterator> typename std::iterator_traits<_Iterator>::difference_type std::distance(_InputIterator, _InputIterator)
     distance(_InputIterator __first, _InputIterator __last)
     ^
0_0_25304930_10629.cpp:57:36: error: reference to 'distance' is ambiguous
          if(!vis[j]&&dis[j]>dis[k]+distance[k][j])
                                    ^
0_0_25304930_10629.cpp:9:5: note: candidates are: int distance [1010][1010]
 int distance[maxn][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++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_25304930_10629.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:114:5: note:                 template<class _InputIterator> typename std::iterator_traits<_Iterator>::difference_type std::distance(_InputIterator, _InputIterator)
     distance(_InputIterator __first, _InputIterator __last)
     ^
0_0_25304930_10629.cpp:59:28: error: reference to 'distance' is ambiguous
              dis[j]=dis[k]+distance[k][j];
                            ^
0_0_25304930_10629.cpp:9:5: note: candidates are: int distance [1010][1010]
 int distance[maxn][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++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_25304930_10629.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:114:5: note:                 template<class _InputIterator> typename std::iterator_traits<_Iterator>::difference_type std::distance(_InputIterator, _InputIterator)
     distance(_InputIterator __first, _InputIterator __last)
     ^
0_0_25304930_10629.cpp:62:45: error: reference to 'distance' is ambiguous
             else if(!vis[j]&&dis[j]==dis[k]+distance[k][j]&&cos[j]>cos[k]+pay[k][j])
                                             ^
0_0_25304930_10629.cpp:9:5: note: candidates are: int distance [1010][1010]
 int distance[maxn][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++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_25304930_10629.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:114:5: note:                 template<class _InputIterator> typename std::iterator_traits<_Iterator>::difference_type std::distance(_InputIterator, _InputIterator)
     distance(_InputIterator __first, _InputIterator __last)
     ^
0_0_25304930_10629.cpp: In function 'int main()':
0_0_25304930_10629.cpp:83:24: error: invalid types 'int[int]' for array subscript
                     d[i][j]=0;
                        ^
0_0_25304930_10629.cpp:84:24: error: invalid types 'int[int]' for array subscript
                     p[i][j]=0;
                        ^
0_0_25304930_10629.cpp:88:24: error: invalid types 'int[int]' for array subscript
                     d[i][j]=MAX;
                        ^
0_0_25304930_10629.cpp:88:29: error: 'MAX' was not declared in this scope
                     d[i][j]=MAX;
                             ^
0_0_25304930_10629.cpp:89:24: error: invalid types 'int[int]' for array subscript
                     p[i][j]=MAX;
                        ^
0_0_25304930_10629.cpp:98:18: error: reference to 'distance' is ambiguous
             if(d<distance[a][b])
                  ^
0_0_25304930_10629.cpp:9:5: note: candidates are: int distance [1010][1010]
 int distance[maxn][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++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_25304930_10629.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:114:5: note:                 template<class _InputIterator> typename std::iterator_traits<_Iterator>::difference_type std::distance(_InputIterator, _InputIterator)
     distance(_InputIterator __first, _InputIterator __last)
     ^
0_0_25304930_10629.cpp:100:14: error: reference to 'distance' is ambiguous
              distance[a][b]=distance[b][a]=d;
              ^
0_0_25304930_10629.cpp:9:5: note: candidates are: int distance [1010][1010]
 int distance[maxn][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++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_25304930_10629.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:114:5: note:                 template<class _InputIterator> typename std::iterator_traits<_Iterator>::difference_type std::distance(_InputIterator, _InputIterator)
     distance(_InputIterator __first, _InputIterator __last)
     ^
0_0_25304930_10629.cpp:100:29: error: reference to 'distance' is ambiguous
              distance[a][b]=distance[b][a]=d;
                             ^
0_0_25304930_10629.cpp:9:5: note: candidates are: int distance [1010][1010]
 int distance[maxn][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++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_25304930_10629.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:114:5: note:                 template<class _InputIterator> typename std::iterator_traits<_Iterator>::difference_type std::distance(_InputIterator, _InputIterator)
     distance(_InputIterator __first, _InputIterator __last)
     ^
0_0_25304930_10629.cpp:106:23: error: invalid types 'int[int]' for array subscript
         cout<<dis[s][t]<<" "<<cos[s][t]<<endl;
                       ^
0_0_25304930_10629.cpp:106:39: error: invalid types 'int[int]' for array subscript
         cout<<dis[s][t]<<" "<<cos[s][t]<<endl;
                                       ^


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-17 07:54:24, Gzip enabled